/usr/include/adf/ADF.h is in libcgns-dev 3.3.0-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 53 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 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 | /* ------------------------------------------------------------------------- *
* CGNS - CFD General Notation System (http://www.cgns.org) *
* CGNS/MLL - Mid-Level Library header file *
* Please see cgnsconfig.h file for this local installation configuration *
* ------------------------------------------------------------------------- */
/* ------------------------------------------------------------------------- *
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from
the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not
be misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
* ------------------------------------------------------------------------- */
/**
File: ADF.h
----------------------------------------------------------------------
BOEING
----------------------------------------------------------------------
Project: CGNS
Author: Tom Dickens 865-6122 tpd6908@yak.ca.boeing.com
Date: 3/2/1995
Purpose: Provide prototype declarations for the ADF-Core routines.
----------------------------------------------------------------------
----------------------------------------------------------------------
**/
#ifndef ADF_INCLUDE
#define ADF_INCLUDE
#include "cgnstypes.h"
#if defined(_WIN32) && defined(BUILD_DLL)
# define EXTERN extern _declspec(dllexport)
#else
# define EXTERN extern
#endif
/***********************************************************************
Defines: These defines are used within the ADF core routines
to specify the size in bytes of varoius items.
Caution: Simply changing a define here may not correctly adjust the
ADF core code. These sizes are provided for reference only!
***********************************************************************/
#define ADF_DATA_TYPE_LENGTH 32
#define ADF_DATE_LENGTH 32
#define ADF_FILENAME_LENGTH 1024
#define ADF_FORMAT_LENGTH 20
#define ADF_LABEL_LENGTH 32
#define ADF_MAXIMUM_LINK_DEPTH 100
#define ADF_MAX_DIMENSIONS 12
#define ADF_MAX_ERROR_STR_LENGTH 80
#define ADF_MAX_LINK_DATA_SIZE 4096
#define ADF_NAME_LENGTH 32
#define ADF_STATUS_LENGTH 32
#define ADF_VERSION_LENGTH 32
/***********************************************************************
Prototypes for Interface Routines
***********************************************************************/
#if defined (__cplusplus)
extern "C" {
#endif
EXTERN void ADF_Children_Names(
const double PID,
const int istart,
const int ilen,
const int name_length,
int *ilen_ret,
char *names,
int *error_return ) ;
EXTERN void ADF_Children_IDs(
const double PID,
const int istart,
const int ilen,
int *ilen_ret,
double *IDs,
int *error_return ) ;
EXTERN void ADF_Create(
const double PID,
const char *name,
double *ID,
int *error_return ) ;
EXTERN void ADF_Database_Close(
const double ID,
int *error_return ) ;
EXTERN void ADF_Database_Delete(
const char *filename,
int *error_return ) ;
EXTERN void ADF_Database_Garbage_Collection(
const double ID,
int *error_return ) ;
EXTERN void ADF_Database_Get_Format(
const double Root_ID,
char *format,
int *error_return ) ;
EXTERN void ADF_Database_Open(
const char *filename,
const char *status,
const char *format,
double *root_ID,
int *error_return ) ;
EXTERN void ADF_Database_Valid(
const char *filename,
int *error_return ) ;
EXTERN void ADF_Database_Set_Format(
const double Root_ID,
const char *format,
int *error_return ) ;
EXTERN void ADF_Database_Version(
const double Root_ID,
char *version,
char *creation_date,
char *modification_date,
int *error_return ) ;
EXTERN void ADF_Delete(
const double PID,
const double ID,
int *error_return ) ;
EXTERN void ADF_Error_Message(
const int error_return_input,
char *error_string ) ;
EXTERN void ADF_Flush_to_Disk(
const double ID,
int *error_return ) ;
EXTERN void ADF_Get_Data_Type(
const double ID,
char *data_type,
int *error_return ) ;
EXTERN void ADF_Get_Dimension_Values(
const double ID,
cgsize_t dim_vals[],
int *error_return ) ;
EXTERN void ADF_Get_Error_State(
int *error_state,
int *error_return ) ;
EXTERN void ADF_Get_Label(
const double ID,
char *label,
int *error_return ) ;
EXTERN void ADF_Get_Link_Path(
const double ID,
char *filename,
char *link_path,
int *error_return ) ;
EXTERN void ADF_Get_Name(
const double ID,
char *name,
int *error_return ) ;
EXTERN void ADF_Get_Node_ID(
const double PID,
const char *name,
double *ID,
int *error_return ) ;
EXTERN void ADF_Get_Number_of_Dimensions(
const double ID,
int *num_dims,
int *error_return ) ;
EXTERN void ADF_Get_Root_ID(
const double ID,
double *Root_ID,
int *error_return ) ;
EXTERN void ADF_Is_Link(
const double ID,
int *link_path_length,
int *error_return ) ;
EXTERN void ADF_Library_Version(
char *version,
int *error_return ) ;
EXTERN void ADF_Link(
const double PID,
const char *name,
const char *file,
const char *name_in_file,
double *ID,
int *error_return ) ;
EXTERN void ADF_Link_Size(
const double ID,
int *len_file,
int *len_name,
int *error_return ) ;
EXTERN void ADF_Move_Child(
const double PID,
const double ID,
const double NPID,
int *error_return ) ;
EXTERN void ADF_Number_of_Children(
const double ID,
int *num_children,
int *error_return ) ;
EXTERN void ADF_Put_Dimension_Information(
const double ID,
const char *data_type,
const int dims,
const cgsize_t dim_vals[],
int *error_return ) ;
EXTERN void ADF_Put_Name(
const double PID,
const double ID,
const char *name,
int *error_return ) ;
EXTERN void ADF_Read_All_Data(
const double ID,
char *data,
int *error_return ) ;
EXTERN void ADF_Read_Block_Data(
const double ID,
const cgsize_t b_start,
const cgsize_t b_end,
char *data,
int *error_return ) ;
EXTERN void ADF_Read_Data(
const double ID,
const cgsize_t s_start[],
const cgsize_t s_end[],
const cgsize_t s_stride[],
const int m_num_dims,
const cgsize_t m_dims[],
const cgsize_t m_start[],
const cgsize_t m_end[],
const cgsize_t m_stride[],
char *data,
int *error_return ) ;
EXTERN void ADF_Set_Error_State(
const int error_state,
int *error_return ) ;
EXTERN void ADF_Set_Label(
const double ID,
const char *label,
int *error_return ) ;
EXTERN void ADF_Write_All_Data(
const double ID,
const char *data,
int *error_return ) ;
EXTERN void ADF_Write_Block_Data(
const double ID,
const cgsize_t b_start,
const cgsize_t b_end,
char *data,
int *error_return ) ;
EXTERN void ADF_Write_Data(
const double ID,
const cgsize_t s_start[],
const cgsize_t s_end[],
const cgsize_t s_stride[],
const int m_num_dims,
const cgsize_t m_dims[],
const cgsize_t m_start[],
const cgsize_t m_end[],
const cgsize_t m_stride[],
const char *data,
int *error_return ) ;
#if defined (__cplusplus)
}
#endif
#undef EXTERN
/***********************************************************************
Error-return values
These values need to be kept in sync with the error strings in
file ADF_interface.c
***********************************************************************/
/** Don't use zero since you can assign zero to a pointer **/
#define NO_ERROR -1
#define NUMBER_LESS_THAN_MINIMUM 1
#define NUMBER_GREATER_THAN_MAXIMUM 2
#define STRING_LENGTH_ZERO 3
#define STRING_LENGTH_TOO_BIG 4
#define STRING_NOT_A_HEX_STRING 5
#define TOO_MANY_ADF_FILES_OPENED 6
#define ADF_FILE_STATUS_NOT_RECOGNIZED 7
#define FILE_OPEN_ERROR 8
#define ADF_FILE_NOT_OPENED 9
#define FILE_INDEX_OUT_OF_RANGE 10
#define BLOCK_OFFSET_OUT_OF_RANGE 11
#define NULL_STRING_POINTER 12
#define FSEEK_ERROR 13
#define FWRITE_ERROR 14
#define FREAD_ERROR 15
#define ADF_MEMORY_TAG_ERROR 16
#define ADF_DISK_TAG_ERROR 17
#define REQUESTED_NEW_FILE_EXISTS 18
#define ADF_FILE_FORMAT_NOT_RECOGNIZED 19
#define FREE_OF_ROOT_NODE 20
#define FREE_OF_FREE_CHUNK_TABLE 21
#define REQUESTED_OLD_FILE_NOT_FOUND 22
#define UNIMPLEMENTED_CODE 23
#define SUB_NODE_TABLE_ENTRIES_BAD 24
#define MEMORY_ALLOCATION_FAILED 25
#define DUPLICATE_CHILD_NAME 26
#define ZERO_DIMENSIONS 27
#define BAD_NUMBER_OF_DIMENSIONS 28
#define CHILD_NOT_OF_GIVEN_PARENT 29
#define DATA_TYPE_TOO_LONG 30
#define INVALID_DATA_TYPE 31
#define NULL_POINTER 32
#define NO_DATA 33
#define ERROR_ZEROING_OUT_MEMORY 34
#define REQUESTED_DATA_TOO_LONG 35
#define END_OUT_OF_DEFINED_RANGE 36
#define BAD_STRIDE_VALUE 37
#define MINIMUM_GT_MAXIMUM 38
#define MACHINE_FORMAT_NOT_RECOGNIZED 39
#define CANNOT_CONVERT_NATIVE_FORMAT 40
#define CONVERSION_FORMATS_EQUAL 41
#define DATA_TYPE_NOT_SUPPORTED 42
#define FILE_CLOSE_ERROR 43
#define NUMERIC_OVERFLOW 44
#define START_OUT_OF_DEFINED_RANGE 45
#define ZERO_LENGTH_VALUE 46
#define BAD_DIMENSION_VALUE 47
#define BAD_ERROR_STATE 48
#define UNEQUAL_MEMORY_AND_DISK_DIMS 49
#define LINKS_TOO_DEEP 50
#define NODE_IS_NOT_A_LINK 51
#define LINK_TARGET_NOT_THERE 52
#define LINKED_TO_FILE_NOT_THERE 53
#define NODE_ID_ZERO 54
#define INCOMPLETE_DATA 55
#define INVALID_NODE_NAME 56
#define INVALID_VERSION 57
#define NODES_NOT_IN_SAME_FILE 58
#define PRISTK_NOT_FOUND 59
#define MACHINE_FILE_INCOMPATABLE 60
#define FFLUSH_ERROR 61
#define NULL_NODEID_POINTER 62
#define MAX_FILE_SIZE_EXCEEDED 63
#define MAX_INT32_SIZE_EXCEEDED 64
#endif
|