[83] | 1 | /* |
---|
| 2 | * ---------------------------------------------------------------------- |
---|
| 3 | * INTERFACE: Fortran Rappture Library Header |
---|
| 4 | * |
---|
| 5 | * ====================================================================== |
---|
[93] | 6 | * AUTHOR: Derrick S. Kearney, Purdue University |
---|
[591] | 7 | * Copyright (c) 2004-2007 Purdue Research Foundation |
---|
[115] | 8 | * |
---|
| 9 | * See the file "license.terms" for information on usage and |
---|
| 10 | * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
---|
[83] | 11 | * ====================================================================== |
---|
| 12 | */ |
---|
[77] | 13 | |
---|
[656] | 14 | #ifndef _RAPPTURE_LIBRARY_F_H |
---|
| 15 | #define _RAPPTURE_LIBRARY_F_H |
---|
[77] | 16 | |
---|
[84] | 17 | #ifdef __cplusplus |
---|
[554] | 18 | #include "RpLibrary.h" |
---|
| 19 | #include <string.h> |
---|
| 20 | #include <fstream> |
---|
| 21 | #include "RpFortranCommon.h" |
---|
| 22 | #include "RpLibraryFStubs.h" |
---|
| 23 | |
---|
[77] | 24 | extern "C" { |
---|
[554] | 25 | #endif // ifdef __cplusplus |
---|
[77] | 26 | |
---|
[83] | 27 | int rp_lib ( const char* filePath, int filePath_len ); |
---|
[77] | 28 | |
---|
[83] | 29 | void rp_lib_element_comp ( int* handle, |
---|
[77] | 30 | char* path, |
---|
| 31 | char* retText, |
---|
| 32 | int path_len, |
---|
| 33 | int retText_len ); |
---|
| 34 | |
---|
[83] | 35 | void rp_lib_element_id ( int* handle, |
---|
[77] | 36 | char* path, |
---|
| 37 | char* retText, |
---|
| 38 | int path_len, |
---|
| 39 | int retText_len ); |
---|
| 40 | |
---|
[83] | 41 | void rp_lib_element_type ( int* handle, |
---|
[77] | 42 | char* path, |
---|
| 43 | char* retText, |
---|
| 44 | int path_len, |
---|
| 45 | int retText_len ); |
---|
| 46 | |
---|
[83] | 47 | int rp_lib_element_obj ( int* handle, |
---|
[77] | 48 | char* path, |
---|
| 49 | int path_len ); |
---|
| 50 | |
---|
[83] | 51 | int rp_lib_children ( int* handle, /* integer handle of library */ |
---|
| 52 | char* path, /* search path of the xml */ |
---|
| 53 | int* childHandle, /*int handle of last returned child*/ |
---|
| 54 | int path_len /*length of the search path buffer*/ |
---|
| 55 | ); |
---|
[77] | 56 | |
---|
[84] | 57 | void rp_lib_get ( int* handle, |
---|
[77] | 58 | char* path, |
---|
| 59 | char* retText, |
---|
| 60 | int path_len, |
---|
| 61 | int retText_len ); |
---|
| 62 | |
---|
[125] | 63 | void rp_lib_get_str ( int* handle, |
---|
| 64 | char* path, |
---|
| 65 | char* retText, |
---|
| 66 | int path_len, |
---|
| 67 | int retText_len ); |
---|
| 68 | |
---|
[84] | 69 | double rp_lib_get_double ( int* handle, |
---|
[77] | 70 | char* path, |
---|
| 71 | int path_len); |
---|
| 72 | |
---|
[496] | 73 | int rp_lib_get_integer ( int* handle, |
---|
| 74 | char* path, |
---|
| 75 | int path_len); |
---|
| 76 | |
---|
| 77 | int rp_lib_get_boolean ( int* handle, |
---|
| 78 | char* path, |
---|
| 79 | int path_len); |
---|
| 80 | |
---|
[2408] | 81 | int rp_lib_get_file ( int* handle, |
---|
| 82 | char* path, |
---|
| 83 | char* fileName, |
---|
| 84 | int path_len, |
---|
| 85 | int fileName_len); |
---|
| 86 | |
---|
[84] | 87 | void rp_lib_put_str ( int* handle, |
---|
| 88 | char* path, |
---|
| 89 | char* value, |
---|
[77] | 90 | int* append, |
---|
| 91 | int path_len, |
---|
[84] | 92 | int value_len ); |
---|
[77] | 93 | |
---|
[84] | 94 | void rp_lib_put_id_str ( int* handle, |
---|
| 95 | char* path, |
---|
| 96 | char* value, |
---|
| 97 | char* id, |
---|
[77] | 98 | int* append, |
---|
| 99 | int path_len, |
---|
| 100 | int value_len, |
---|
[84] | 101 | int id_len ); |
---|
[77] | 102 | |
---|
[591] | 103 | void rp_lib_put_data ( int* handle, |
---|
| 104 | char* path, |
---|
| 105 | char* bytes, |
---|
| 106 | int* nbytes, |
---|
| 107 | int* append, |
---|
| 108 | int path_len, |
---|
| 109 | int bytes_len ); |
---|
| 110 | |
---|
| 111 | void rp_lib_put_file ( int* handle, |
---|
| 112 | char* path, |
---|
| 113 | char* fileName, |
---|
[597] | 114 | int* compress, |
---|
[591] | 115 | int* append, |
---|
| 116 | int path_len, |
---|
| 117 | int fileName_len ); |
---|
| 118 | |
---|
[84] | 119 | /* |
---|
| 120 | * rp_lib_put_obj still needs to be written |
---|
| 121 | * keep function declaration around |
---|
[1086] | 122 | */ |
---|
[84] | 123 | void rp_lib_put_obj ( int* handle, |
---|
| 124 | char* path, |
---|
| 125 | int* valHandle, |
---|
[77] | 126 | int* append, |
---|
[84] | 127 | int path_len ); |
---|
[77] | 128 | |
---|
[84] | 129 | /* |
---|
| 130 | * rp_lib_put_id_obj still needs to be written |
---|
| 131 | * keep function declaration around |
---|
| 132 | void rp_lib_put_id_obj ( int* handle, |
---|
| 133 | char* path, |
---|
| 134 | int* valHandle, |
---|
| 135 | char* id, |
---|
[77] | 136 | int* append, |
---|
| 137 | int path_len, |
---|
[84] | 138 | int id_len ); |
---|
| 139 | */ |
---|
[77] | 140 | |
---|
[84] | 141 | /* |
---|
| 142 | * rp_lib_remove still needs to be written |
---|
| 143 | * keep function declaration around |
---|
[83] | 144 | int rp_lib_remove ( int* handle, |
---|
| 145 | char* path, |
---|
[77] | 146 | int path_len); |
---|
[84] | 147 | */ |
---|
[77] | 148 | |
---|
[84] | 149 | /* |
---|
| 150 | * rp_lib_xml_len still needs to be written |
---|
| 151 | * keep function declaration around |
---|
[83] | 152 | int rp_lib_xml_len( int* handle); |
---|
[84] | 153 | */ |
---|
[77] | 154 | |
---|
[83] | 155 | void rp_lib_xml( int* handle, |
---|
| 156 | char* retText, |
---|
[77] | 157 | int retText_len); |
---|
| 158 | |
---|
[83] | 159 | int rp_lib_write_xml( int* handle, |
---|
| 160 | char* outFile, |
---|
[77] | 161 | int outFile_len); |
---|
[83] | 162 | |
---|
| 163 | void rp_lib_node_comp ( int* handle, |
---|
| 164 | char* retText, |
---|
| 165 | int retText_len); |
---|
| 166 | |
---|
| 167 | void rp_lib_node_type ( int* handle, |
---|
| 168 | char* retText, |
---|
| 169 | int retText_len); |
---|
| 170 | |
---|
| 171 | void rp_lib_node_id ( int* handle, |
---|
| 172 | char* retText, |
---|
| 173 | int retText_len); |
---|
| 174 | |
---|
| 175 | void rp_result( int* handle ); |
---|
| 176 | |
---|
[77] | 177 | /**********************************************************/ |
---|
| 178 | |
---|
[84] | 179 | #ifdef __cplusplus |
---|
[77] | 180 | } |
---|
[554] | 181 | #endif // ifdef __cplusplus |
---|
| 182 | |
---|
[656] | 183 | #endif // ifndef _RAPPTURE_LIBRARY_F_H |
---|