Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/*
* Distributed under the OSI-approved Apache License, Version 2.0. See
* accompanying file Copyright.txt for details.
*
* adios2_f2c_engine.cpp
*
* Created on: Nov 8, 2017
* Author: William F Godoy godoywf@ornl.gov
*/
#include "adios2_f2c_engine.h"
#include <stdexcept>
void FC_GLOBAL(adios2_begin_step_f2c,
ADIOS2_BEGIN_STEP_F2C)(adios2_Engine **engine, int *ierr)
{
*ierr = 0;
try
{
adios2_begin_step(*engine);
}
catch (std::exception &e)
{
*ierr = 1;
}
}
void FC_GLOBAL(adios2_put_sync_f2c,
ADIOS2_PUT_SYNC_F2C)(adios2_Engine **engine,
adios2_Variable **variable,
const void *values, int *ierr)
{
*ierr = 0;
try
{
adios2_put_sync(*engine, *variable, values);
}
catch (std::exception &e)
{
*ierr = 1;
}
}
void FC_GLOBAL(adios2_put_deferred_f2c,
ADIOS2_PUT_DEFERRED_F2C)(adios2_Engine **engine,
adios2_Variable **variable,
const void *values, int *ierr)
{
*ierr = 0;
try
{
adios2_put_deferred(*engine, *variable, values);
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
}
catch (std::exception &e)
{
*ierr = 1;
}
}
void FC_GLOBAL(adios2_end_step_f2c, ADIOS2_END_STEP_F2C)(adios2_Engine **engine,
int *ierr)
{
*ierr = 0;
try
{
adios2_end_step(*engine);
}
catch (std::exception &e)
{
*ierr = 1;
}
}
void FC_GLOBAL(adios2_close_f2c, ADIOS2_CLOSE_F2C)(adios2_Engine **engine,
int *ierr)
{
*ierr = 0;
try
{
adios2_close(*engine);
}
catch (std::exception &e)
{
*ierr = 1;
}
}