19 #if defined(_WIN32) || defined(_WIN64)
30 #if defined(__cplusplus)
42 #define NC_LONG NC_INT
52 #define NC_MAX_ATOMIC_TYPE NC_STRING
59 #define NC_COMPOUND 16
62 #define NC_FIRSTUSERTYPEID 32
69 #define NC_FILL_BYTE ((signed char)-127)
70 #define NC_FILL_CHAR ((char)0)
71 #define NC_FILL_SHORT ((short)-32767)
72 #define NC_FILL_INT (-2147483647L)
73 #define NC_FILL_FLOAT (9.9692099683868690e+36f)
74 #define NC_FILL_DOUBLE (9.9692099683868690e+36)
75 #define NC_FILL_UBYTE (255)
76 #define NC_FILL_USHORT (65535)
77 #define NC_FILL_UINT (4294967295U)
78 #define NC_FILL_INT64 ((long long)-9223372036854775806LL)
79 #define NC_FILL_UINT64 ((unsigned long long)18446744073709551614ULL)
80 #define NC_FILL_STRING ((char *)"")
91 #define NC_MAX_BYTE 127
92 #define NC_MIN_BYTE (-NC_MAX_BYTE-1)
93 #define NC_MAX_CHAR 255
94 #define NC_MAX_SHORT 32767
95 #define NC_MIN_SHORT (-NC_MAX_SHORT - 1)
96 #define NC_MAX_INT 2147483647
97 #define NC_MIN_INT (-NC_MAX_INT - 1)
98 #define NC_MAX_FLOAT 3.402823466e+38f
99 #define NC_MIN_FLOAT (-NC_MAX_FLOAT)
100 #define NC_MAX_DOUBLE 1.7976931348623157e+308
101 #define NC_MIN_DOUBLE (-NC_MAX_DOUBLE)
102 #define NC_MAX_UBYTE NC_MAX_CHAR
103 #define NC_MAX_USHORT 65535U
104 #define NC_MAX_UINT 4294967295U
105 #define NC_MAX_INT64 (9223372036854775807LL)
106 #define NC_MIN_INT64 (-9223372036854775807LL-1)
107 #define NC_MAX_UINT64 (18446744073709551615ULL)
108 #define X_INT64_MAX (9223372036854775807LL)
109 #define X_INT64_MIN (-X_INT64_MAX - 1)
110 #define X_UINT64_MAX (18446744073709551615ULL)
118 #define _FillValue "_FillValue"
120 #define NC_NOFILL 0x100
127 #define NC_NOWRITE 0x0000
128 #define NC_WRITE 0x0001
130 #define NC_CLOBBER 0x0000
131 #define NC_NOCLOBBER 0x0004
133 #define NC_DISKLESS 0x0008
134 #define NC_MMAP 0x0010
136 #define NC_CLASSIC_MODEL 0x0100
137 #define NC_64BIT_OFFSET 0x0200
143 #define NC_LOCK 0x0400
147 #define NC_SHARE 0x0800
149 #define NC_NETCDF4 0x1000
153 #define NC_MPIIO 0x2000
156 #define NC_MPIPOSIX 0x4000
157 #define NC_PNETCDF 0x8000
166 #define NC_FORMAT_CLASSIC (1)
167 #define NC_FORMAT_64BIT (2)
168 #define NC_FORMAT_NETCDF4 (3)
169 #define NC_FORMAT_NETCDF4_CLASSIC (4)
189 #define NC_FORMAT_NC3 (1)
190 #define NC_FORMAT_NC_HDF5 (2)
191 #define NC_FORMAT_NC_HDF4 (3)
192 #define NC_FORMAT_PNETCDF (4)
193 #define NC_FORMAT_DAP2 (5)
194 #define NC_FORMAT_DAP4 (6)
195 #define NC_FORMAT_UNDEFINED (0)
199 #define NC_SIZEHINT_DEFAULT 0
202 #define NC_ALIGN_CHUNK ((size_t)(-1))
205 #define NC_UNLIMITED 0L
229 #define NC_MAX_DIMS 1024
230 #define NC_MAX_ATTRS 8192
231 #define NC_MAX_VARS 8192
232 #define NC_MAX_NAME 256
233 #define NC_MAX_VAR_DIMS 1024
237 #define NC_MAX_HDF4_NAME 64
242 #define NC_ENDIAN_NATIVE 0
243 #define NC_ENDIAN_LITTLE 1
244 #define NC_ENDIAN_BIG 2
252 #define NC_CONTIGUOUS 1
260 #define NC_NOCHECKSUM 0
261 #define NC_FLETCHER32 1
269 #define NC_NOSHUFFLE 0
277 #define NC_ISSYSERR(err) ((err) > 0)
286 #define NC_EBADID (-33)
287 #define NC_ENFILE (-34)
288 #define NC_EEXIST (-35)
289 #define NC_EINVAL (-36)
290 #define NC_EPERM (-37)
295 #define NC_ENOTINDEFINE (-38)
304 #define NC_EINDEFINE (-39)
311 #define NC_EINVALCOORDS (-40)
312 #define NC_EMAXDIMS (-41)
313 #define NC_ENAMEINUSE (-42)
314 #define NC_ENOTATT (-43)
315 #define NC_EMAXATTS (-44)
316 #define NC_EBADTYPE (-45)
317 #define NC_EBADDIM (-46)
318 #define NC_EUNLIMPOS (-47)
323 #define NC_EMAXVARS (-48)
328 #define NC_ENOTVAR (-49)
329 #define NC_EGLOBAL (-50)
330 #define NC_ENOTNC (-51)
331 #define NC_ESTS (-52)
332 #define NC_EMAXNAME (-53)
333 #define NC_EUNLIMIT (-54)
334 #define NC_ENORECVARS (-55)
335 #define NC_ECHAR (-56)
344 #define NC_EEDGE (-57)
345 #define NC_ESTRIDE (-58)
346 #define NC_EBADNAME (-59)
353 #define NC_ERANGE (-60)
354 #define NC_ENOMEM (-61)
355 #define NC_EVARSIZE (-62)
356 #define NC_EDIMSIZE (-63)
357 #define NC_ETRUNC (-64)
358 #define NC_EAXISTYPE (-65)
361 #define NC_EDAP (-66)
362 #define NC_ECURL (-67)
364 #define NC_ENODATA (-69)
365 #define NC_EDAPSVC (-70)
366 #define NC_EDAS (-71)
367 #define NC_EDDS (-72)
368 #define NC_EDATADDS (-73)
369 #define NC_EDAPURL (-74)
370 #define NC_EDAPCONSTRAINT (-75)
371 #define NC_ETRANSLATION (-76)
372 #define NC_EACCESS (-77)
373 #define NC_EAUTH (-78)
376 #define NC_ENOTFOUND (-90)
377 #define NC_ECANTREMOVE (-91)
382 #define NC4_FIRST_ERROR (-100)
385 #define NC_EHDFERR (-101)
386 #define NC_ECANTREAD (-102)
387 #define NC_ECANTWRITE (-103)
388 #define NC_ECANTCREATE (-104)
389 #define NC_EFILEMETA (-105)
390 #define NC_EDIMMETA (-106)
391 #define NC_EATTMETA (-107)
392 #define NC_EVARMETA (-108)
393 #define NC_ENOCOMPOUND (-109)
394 #define NC_EATTEXISTS (-110)
395 #define NC_ENOTNC4 (-111)
398 #define NC_ESTRICTNC3 (-112)
399 #define NC_ENOTNC3 (-113)
400 #define NC_ENOPAR (-114)
401 #define NC_EPARINIT (-115)
402 #define NC_EBADGRPID (-116)
403 #define NC_EBADTYPID (-117)
404 #define NC_ETYPDEFINED (-118)
405 #define NC_EBADFIELD (-119)
406 #define NC_EBADCLASS (-120)
407 #define NC_EMAPTYPE (-121)
408 #define NC_ELATEFILL (-122)
409 #define NC_ELATEDEF (-123)
410 #define NC_EDIMSCALE (-124)
411 #define NC_ENOGRP (-125)
412 #define NC_ESTORAGE (-126)
413 #define NC_EBADCHUNK (-127)
414 #define NC_ENOTBUILT (-128)
415 #define NC_EDISKLESS (-129)
416 #define NC_ECANTEXTEND (-130)
417 #define NC_EMPI (-131)
419 #define NC4_LAST_ERROR (-131)
423 #define DIM_WITHOUT_VARIABLE "This is a netCDF dimension but not a netCDF variable."
427 #define NC_HAVE_NEW_CHUNKING_API 1
431 #define NC_EURL (NC_EDAPURL)
432 #define NC_ECONSTRAINT (NC_EDAPCONSTRAINT)
440 #if defined(DLL_NETCDF)
441 # if defined(DLL_EXPORT)
442 # define MSC_EXTRA __declspec(dllexport)
444 # define MSC_EXTRA __declspec(dllimport)
451 # define EXTERNL MSC_EXTRA extern
453 #if defined(DLL_NETCDF)
459 nc_inq_libvers(
void);
465 nc__create(
const char *path,
int cmode,
size_t initialsz,
466 size_t *chunksizehintp,
int *ncidp);
469 nc_create(
const char *path,
int cmode,
int *ncidp);
472 nc__open(
const char *path,
int mode,
473 size_t *chunksizehintp,
int *ncidp);
476 nc_open(
const char *path,
int mode,
int *ncidp);
480 nc_inq_path(
int ncid,
size_t *pathlen,
char *path);
485 nc_inq_ncid(
int ncid,
const char *name,
int *grp_ncid);
490 nc_inq_grps(
int ncid,
int *numgrps,
int *ncids);
494 nc_inq_grpname(
int ncid,
char *name);
499 nc_inq_grpname_full(
int ncid,
size_t *lenp,
char *full_name);
503 nc_inq_grpname_len(
int ncid,
size_t *lenp);
507 nc_inq_grp_parent(
int ncid,
int *parent_ncid);
515 nc_inq_grp_full_ncid(
int ncid,
const char *full_name,
int *grp_ncid);
519 nc_inq_varids(
int ncid,
int *nvars,
int *varids);
524 nc_inq_dimids(
int ncid,
int *ndims,
int *dimids,
int include_parents);
529 nc_inq_typeids(
int ncid,
int *ntypes,
int *typeids);
533 nc_inq_type_equal(
int ncid1,
nc_type typeid1,
int ncid2,
538 nc_def_grp(
int parent_ncid,
const char *name,
int *new_ncid);
542 nc_rename_grp(
int grpid,
const char *name);
553 size_t offset,
nc_type field_typeid);
558 size_t offset,
nc_type field_typeid,
559 int ndims,
const int *dim_sizes);
589 size_t *offsetp,
nc_type *field_typeidp,
int *ndimsp,
634 #define NC_COMPOUND_OFFSET(S,M) (offsetof(S,M))
657 nc_put_vlen_element(
int ncid,
int typeid1,
void *vlen_element,
658 size_t len,
const void *data);
661 nc_get_vlen_element(
int ncid,
int typeid1,
const void *vlen_element,
662 size_t *len,
void *data);
674 nc_type *base_nc_typep,
size_t *nfieldsp,
int *classp);
679 size_t len,
const void *op);
683 nc_get_att(
int ncid,
int varid,
const char *name,
void *ip);
703 size_t *base_sizep,
size_t *num_membersp);
728 nc_put_var(
int ncid,
int varid,
const void *op);
736 nc_put_var1(
int ncid,
int varid,
const size_t *indexp,
741 nc_get_var1(
int ncid,
int varid,
const size_t *indexp,
void *ip);
745 nc_put_vara(
int ncid,
int varid,
const size_t *startp,
746 const size_t *countp,
const void *op);
750 nc_get_vara(
int ncid,
int varid,
const size_t *startp,
751 const size_t *countp,
void *ip);
755 nc_put_vars(
int ncid,
int varid,
const size_t *startp,
756 const size_t *countp,
const ptrdiff_t *stridep,
761 nc_get_vars(
int ncid,
int varid,
const size_t *startp,
762 const size_t *countp,
const ptrdiff_t *stridep,
767 nc_put_varm(
int ncid,
int varid,
const size_t *startp,
768 const size_t *countp,
const ptrdiff_t *stridep,
769 const ptrdiff_t *imapp,
const void *op);
773 nc_get_varm(
int ncid,
int varid,
const size_t *startp,
774 const size_t *countp,
const ptrdiff_t *stridep,
775 const ptrdiff_t *imapp,
void *ip);
782 nc_def_var_deflate(
int ncid,
int varid,
int shuffle,
int deflate,
788 int *deflatep,
int *deflate_levelp);
792 nc_inq_var_szip(
int ncid,
int varid,
int *options_maskp,
int *pixels_per_blockp);
797 nc_def_var_fletcher32(
int ncid,
int varid,
int fletcher32);
806 nc_def_var_chunking(
int ncid,
int varid,
int storage,
const size_t *chunksizesp);
815 nc_def_var_fill(
int ncid,
int varid,
int no_fill,
const void *fill_value);
823 nc_def_var_endian(
int ncid,
int varid,
int endian);
831 nc_set_fill(
int ncid,
int fillmode,
int *old_modep);
836 nc_set_default_format(
int format,
int *old_formatp);
840 nc_set_chunk_cache(
size_t size,
size_t nelems,
float preemption);
844 nc_get_chunk_cache(
size_t *sizep,
size_t *nelemsp,
float *preemptionp);
861 nc__enddef(
int ncid,
size_t h_minfree,
size_t v_align,
862 size_t v_minfree,
size_t r_align);
877 nc_inq(
int ncid,
int *ndimsp,
int *nvarsp,
int *nattsp,
int *unlimdimidp);
883 nc_inq_nvars(
int ncid,
int *nvarsp);
906 nc_def_dim(
int ncid,
const char *name,
size_t len,
int *idp);
912 nc_inq_dim(
int ncid,
int dimid,
char *name,
size_t *lenp);
927 nc_inq_att(
int ncid,
int varid,
const char *name,
928 nc_type *xtypep,
size_t *lenp);
931 nc_inq_attid(
int ncid,
int varid,
const char *name,
int *idp);
937 nc_inq_attlen(
int ncid,
int varid,
const char *name,
size_t *lenp);
943 nc_copy_att(
int ncid_in,
int varid_in,
const char *name,
int ncid_out,
int varid_out);
946 nc_rename_att(
int ncid,
int varid,
const char *name,
const char *newname);
949 nc_del_att(
int ncid,
int varid,
const char *name);
956 size_t len,
const char *op);
963 size_t len,
const unsigned char *op);
970 size_t len,
const signed char *op);
977 size_t len,
const short *op);
984 size_t len,
const int *op);
991 size_t len,
const long *op);
998 size_t len,
const float *op);
1005 size_t len,
const double *op);
1012 size_t len,
const unsigned short *op);
1019 size_t len,
const unsigned int *op);
1022 nc_get_att_uint(
int ncid,
int varid,
const char *name,
unsigned int *ip);
1026 size_t len,
const long long *op);
1033 size_t len,
const unsigned long long *op);
1037 unsigned long long *ip);
1041 size_t len,
const char **op);
1051 const int *dimidsp,
int *varidp);
1055 int *ndimsp,
int *dimidsp,
int *nattsp);
1079 nc_copy_var(
int ncid_in,
int varid,
int ncid_out);
1083 #define ncvarcpy(ncid_in, varid, ncid_out) ncvarcopy((ncid_in), (varid), (ncid_out))
1090 nc_put_var1_text(
int ncid,
int varid,
const size_t *indexp,
const char *op);
1097 const unsigned char *op);
1105 const signed char *op);
1120 nc_put_var1_int(
int ncid,
int varid,
const size_t *indexp,
const int *op);
1126 nc_put_var1_long(
int ncid,
int varid,
const size_t *indexp,
const long *op);
1145 const unsigned short *op);
1149 unsigned short *ip);
1153 const unsigned int *op);
1161 const long long *op);
1169 const unsigned long long *op);
1173 unsigned long long *ip);
1188 const size_t *countp,
const char *op);
1192 const size_t *countp,
char *ip);
1196 const size_t *countp,
const unsigned char *op);
1200 const size_t *countp,
unsigned char *ip);
1204 const size_t *countp,
const signed char *op);
1208 const size_t *countp,
signed char *ip);
1212 const size_t *countp,
const short *op);
1216 const size_t *countp,
short *ip);
1220 const size_t *countp,
const int *op);
1224 const size_t *countp,
int *ip);
1228 const size_t *countp,
const long *op);
1232 const size_t *startp,
const size_t *countp,
long *ip);
1236 const size_t *startp,
const size_t *countp,
const float *op);
1240 const size_t *startp,
const size_t *countp,
float *ip);
1244 const size_t *countp,
const double *op);
1248 const size_t *countp,
double *ip);
1252 const size_t *countp,
const unsigned short *op);
1256 const size_t *countp,
unsigned short *ip);
1260 const size_t *countp,
const unsigned int *op);
1264 const size_t *countp,
unsigned int *ip);
1268 const size_t *countp,
const long long *op);
1272 const size_t *countp,
long long *ip);
1276 const size_t *countp,
const unsigned long long *op);
1280 const size_t *countp,
unsigned long long *ip);
1284 const size_t *countp,
const char **op);
1288 const size_t *countp,
char **ip);
1295 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1300 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1305 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1306 const unsigned char *op);
1310 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1315 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1316 const signed char *op);
1320 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1325 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1330 const size_t *countp,
const ptrdiff_t *stridep,
1335 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1340 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1345 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1350 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1355 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1360 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1365 const size_t *startp,
const size_t *countp,
const ptrdiff_t *stridep,
1370 const size_t *countp,
const ptrdiff_t *stridep,
1375 const size_t *countp,
const ptrdiff_t *stridep,
1376 const unsigned short *op);
1380 const size_t *countp,
const ptrdiff_t *stridep,
1381 unsigned short *ip);
1385 const size_t *countp,
const ptrdiff_t *stridep,
1386 const unsigned int *op);
1390 const size_t *countp,
const ptrdiff_t *stridep,
1395 const size_t *countp,
const ptrdiff_t *stridep,
1396 const long long *op);
1400 const size_t *countp,
const ptrdiff_t *stridep,
1405 const size_t *countp,
const ptrdiff_t *stridep,
1406 const unsigned long long *op);
1410 const size_t *countp,
const ptrdiff_t *stridep,
1411 unsigned long long *ip);
1415 const size_t *countp,
const ptrdiff_t *stridep,
1420 const size_t *countp,
const ptrdiff_t *stridep,
1428 const size_t *countp,
const ptrdiff_t *stridep,
1429 const ptrdiff_t *imapp,
const char *op);
1433 const size_t *countp,
const ptrdiff_t *stridep,
1434 const ptrdiff_t *imapp,
char *ip);
1438 const size_t *countp,
const ptrdiff_t *stridep,
1439 const ptrdiff_t *imapp,
const unsigned char *op);
1443 const size_t *countp,
const ptrdiff_t *stridep,
1444 const ptrdiff_t *imapp,
unsigned char *ip);
1448 const size_t *countp,
const ptrdiff_t *stridep,
1449 const ptrdiff_t *imapp,
const signed char *op);
1453 const size_t *countp,
const ptrdiff_t *stridep,
1454 const ptrdiff_t *imapp,
signed char *ip);
1458 const size_t *countp,
const ptrdiff_t *stridep,
1459 const ptrdiff_t *imapp,
const short *op);
1463 const size_t *countp,
const ptrdiff_t *stridep,
1464 const ptrdiff_t *imapp,
short *ip);
1468 const size_t *countp,
const ptrdiff_t *stridep,
1469 const ptrdiff_t *imapp,
const int *op);
1473 const size_t *countp,
const ptrdiff_t *stridep,
1474 const ptrdiff_t *imapp,
int *ip);
1478 const size_t *countp,
const ptrdiff_t *stridep,
1479 const ptrdiff_t *imapp,
const long *op);
1483 const size_t *countp,
const ptrdiff_t *stridep,
1484 const ptrdiff_t *imapp,
long *ip);
1488 const size_t *countp,
const ptrdiff_t *stridep,
1489 const ptrdiff_t *imapp,
const float *op);
1493 const size_t *countp,
const ptrdiff_t *stridep,
1494 const ptrdiff_t *imapp,
float *ip);
1498 const size_t *countp,
const ptrdiff_t *stridep,
1499 const ptrdiff_t *imapp,
const double *op);
1503 const size_t *countp,
const ptrdiff_t *stridep,
1504 const ptrdiff_t * imapp,
double *ip);
1508 const size_t *countp,
const ptrdiff_t *stridep,
1509 const ptrdiff_t * imapp,
const unsigned short *op);
1513 const size_t *countp,
const ptrdiff_t *stridep,
1514 const ptrdiff_t * imapp,
unsigned short *ip);
1518 const size_t *countp,
const ptrdiff_t *stridep,
1519 const ptrdiff_t * imapp,
const unsigned int *op);
1523 const size_t *countp,
const ptrdiff_t *stridep,
1524 const ptrdiff_t * imapp,
unsigned int *ip);
1528 const size_t *countp,
const ptrdiff_t *stridep,
1529 const ptrdiff_t * imapp,
const long long *op);
1533 const size_t *countp,
const ptrdiff_t *stridep,
1534 const ptrdiff_t * imapp,
long long *ip);
1538 const size_t *countp,
const ptrdiff_t *stridep,
1539 const ptrdiff_t * imapp,
const unsigned long long *op);
1543 const size_t *countp,
const ptrdiff_t *stridep,
1544 const ptrdiff_t * imapp,
unsigned long long *ip);
1548 const size_t *countp,
const ptrdiff_t *stridep,
1549 const ptrdiff_t * imapp,
const char **op);
1553 const size_t *countp,
const ptrdiff_t *stridep,
1554 const ptrdiff_t * imapp,
char **ip);
1640 size_t len,
const unsigned char *op);
1646 const unsigned char *op);
1652 const size_t *countp,
const unsigned char *op);
1655 const size_t *countp,
unsigned char *ip);
1658 const size_t *countp,
const ptrdiff_t *stridep,
1659 const unsigned char *op);
1662 const size_t *countp,
const ptrdiff_t *stridep,
1666 const size_t *countp,
const ptrdiff_t *stridep,
1667 const ptrdiff_t * imapp,
const unsigned char *op);
1670 const size_t *countp,
const ptrdiff_t *stridep,
1671 const ptrdiff_t * imapp,
unsigned char *ip);
1683 nc_set_log_level(
int new_level);
1687 #define NC_TURN_OFF_LOGGING (-1)
1691 #define nc_set_log_level(e)
1697 nc_show_metadata(
int ncid);
1717 nc__create_mp(
const char *path,
int cmode,
size_t initialsz,
int basepe,
1718 size_t *chunksizehintp,
int *ncidp);
1721 nc__open_mp(
const char *path,
int mode,
int basepe,
1722 size_t *chunksizehintp,
int *ncidp);
1725 nc_delete(
const char *path);
1728 nc_delete_mp(
const char *path,
int basepe);
1731 nc_set_base_pe(
int ncid,
int pe);
1734 nc_inq_base_pe(
int ncid,
int *pe);
1751 #define FILL_BYTE NC_FILL_BYTE
1752 #define FILL_CHAR NC_FILL_CHAR
1753 #define FILL_SHORT NC_FILL_SHORT
1754 #define FILL_LONG NC_FILL_INT
1755 #define FILL_FLOAT NC_FILL_FLOAT
1756 #define FILL_DOUBLE NC_FILL_DOUBLE
1758 #define MAX_NC_DIMS NC_MAX_DIMS
1759 #define MAX_NC_ATTRS NC_MAX_ATTRS
1760 #define MAX_NC_VARS NC_MAX_VARS
1761 #define MAX_NC_NAME NC_MAX_NAME
1762 #define MAX_VAR_DIMS NC_MAX_VAR_DIMS
1771 #define NC_ENTOOL NC_EMAXNAME
1772 #define NC_EXDR (-32)
1773 #define NC_SYSERR (-31)
1780 #define NC_VERBOSE 2
1785 nc_advise(
const char *cdf_routine_name,
int err,
const char *fmt,...);
1796 nccreate(
const char* path,
int cmode);
1799 ncopen(
const char* path,
int mode);
1802 ncsetfill(
int ncid,
int fillmode);
1820 ncinquire(
int ncid,
int *ndimsp,
int *nvarsp,
int *nattsp,
int *unlimdimp);
1823 ncdimdef(
int ncid,
const char *name,
long len);
1826 ncdimid(
int ncid,
const char *name);
1829 ncdiminq(
int ncid,
int dimid,
char *name,
long *lenp);
1832 ncdimrename(
int ncid,
int dimid,
const char *name);
1835 ncattput(
int ncid,
int varid,
const char *name,
nc_type xtype,
1836 int len,
const void *op);
1839 ncattinq(
int ncid,
int varid,
const char *name,
nc_type *xtypep,
int *lenp);
1842 ncattget(
int ncid,
int varid,
const char *name,
void *ip);
1845 ncattcopy(
int ncid_in,
int varid_in,
const char *name,
int ncid_out,
1849 ncattname(
int ncid,
int varid,
int attnum,
char *name);
1852 ncattrename(
int ncid,
int varid,
const char *name,
const char *newname);
1855 ncattdel(
int ncid,
int varid,
const char *name);
1858 ncvardef(
int ncid,
const char *name,
nc_type xtype,
1859 int ndims,
const int *dimidsp);
1862 ncvarid(
int ncid,
const char *name);
1865 ncvarinq(
int ncid,
int varid,
char *name,
nc_type *xtypep,
1866 int *ndimsp,
int *dimidsp,
int *nattsp);
1869 ncvarput1(
int ncid,
int varid,
const long *indexp,
const void *op);
1872 ncvarget1(
int ncid,
int varid,
const long *indexp,
void *ip);
1875 ncvarput(
int ncid,
int varid,
const long *startp,
const long *countp,
1879 ncvarget(
int ncid,
int varid,
const long *startp,
const long *countp,
1883 ncvarputs(
int ncid,
int varid,
const long *startp,
const long *countp,
1884 const long *stridep,
const void *op);
1887 ncvargets(
int ncid,
int varid,
const long *startp,
const long *countp,
1888 const long *stridep,
void *ip);
1891 ncvarputg(
int ncid,
int varid,
const long *startp,
const long *countp,
1892 const long *stridep,
const long *imapp,
const void *op);
1895 ncvargetg(
int ncid,
int varid,
const long *startp,
const long *countp,
1896 const long *stridep,
const long *imapp,
void *ip);
1899 ncvarrename(
int ncid,
int varid,
const char *name);
1902 ncrecinq(
int ncid,
int *nrecvarsp,
int *recvaridsp,
long *recsizesp);
1905 ncrecget(
int ncid,
long recnum,
void **datap);
1908 ncrecput(
int ncid,
long recnum,
void *
const *datap);
1913 #if defined(__cplusplus)
1918 #ifndef __MINGW32_VERSION
1919 #define END_OF_MAIN()
1925 #ifndef NC_HAVE_RENAME_GRP
1926 #define NC_HAVE_RENAME_GRP
1929 #ifndef NC_HAVE_INQ_FORMAT_EXTENDED
1930 #define NC_HAVE_INQ_FORMAT_EXTENDED
1933 #define NC_HAVE_META_H
int nc_get_vara_uint(int ncid, int varid, const size_t *startp, const size_t *countp, unsigned int *ip)
Read an array of values from a variable.
int nc_get_var_uint(int ncid, int varid, unsigned int *ip)
Read an entire variable in one call.
int nc_get_var1_text(int ncid, int varid, const size_t *indexp, char *ip)
Read a single datum from a variable.
EXTERNL int nc__open(const char *path, int mode, size_t *chunksizehintp, int *ncidp)
Open a netCDF file with extra performance parameters for the classic library.
EXTERNL int nc_rename_att(int ncid, int varid, const char *name, const char *newname)
Rename an attribute.
int nc_put_var_long(int ncid, int varid, const long *op)
Write an entire variable with one call.
EXTERNL int nc_def_enum(int ncid, nc_type base_typeid, const char *name, nc_type *typeidp)
Create an enum type.
EXTERNL int nc_inq_atttype(int ncid, int varid, const char *name, nc_type *xtypep)
Find the type of an attribute.
int nc_get_var_ulonglong(int ncid, int varid, unsigned long long *ip)
Read an entire variable in one call.
EXTERNL int nc_inq_var_endian(int ncid, int varid, int *endianp)
Find the endianness of a variable.
int nc_put_varm_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const unsigned char *op)
Write a mapped array of values to a variable.
int nc_put_vars_double(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const double *op)
Write a strided array of values to a variable.
int nc_put_vars_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const unsigned char *op)
Write a strided array of values to a variable.
int nc_get_varm_short(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, short *ip)
Read a mapped array from a variable.
EXTERNL int nc_inq_opaque(int ncid, nc_type xtype, char *name, size_t *sizep)
Learn about an opaque type.
EXTERNL int nc_get_var_chunk_cache(int ncid, int varid, size_t *sizep, size_t *nelemsp, float *preemptionp)
EXTERNL int nc_inq_vardimid(int ncid, int varid, int *dimidsp)
Learn the dimension IDs associated with a variable.
int nc_put_vara_schar(int ncid, int varid, const size_t *startp, const size_t *countp, const signed char *op)
Write an array of values to a variable.
int nc_get_att_ushort(int ncid, int varid, const char *name, unsigned short *value)
Get an attribute.
EXTERNL int nc_inq_att(int ncid, int varid, const char *name, nc_type *xtypep, size_t *lenp)
Return information about a netCDF attribute.
EXTERNL int nc_inq_dimname(int ncid, int dimid, char *name)
Find out the name of a dimension.
int nc_get_varm_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, unsigned char *ip)
Read a mapped array from a variable.
EXTERNL int nc_def_var(int ncid, const char *name, nc_type xtype, int ndims, const int *dimidsp, int *varidp)
Define a new variable.
int nc_put_var1_string(int ncid, int varid, const size_t *indexp, const char **op)
Write one datum.
int nc_get_vara_double(int ncid, int varid, const size_t *startp, const size_t *countp, double *ip)
Read an array of values from a variable.
int nc_put_vars_uint(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const unsigned int *op)
Write a strided array of values to a variable.
EXTERNL int nc_def_dim(int ncid, const char *name, size_t len, int *idp)
Define a new dimension.
int nc_get_varm_float(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, float *ip)
Read a mapped array from a variable.
int nc_put_att_double(int ncid, int varid, const char *name, nc_type xtype, size_t len, const double *value)
Write an attribute.
EXTERNL int nc_inq_grp_ncid(int ncid, const char *grp_name, int *grp_ncid)
This has same semantics as nc_inq_ncid.
int nc_put_vara_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, const unsigned char *op)
Write an array of values to a variable.
EXTERNL int nc_redef(int ncid)
Put open netcdf dataset into define mode.
int nc_get_vars_text(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, char *ip)
Read a strided array from a variable.
int nc_get_vars_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, unsigned char *ip)
Read a strided array from a variable.
EXTERNL int nc__enddef(int ncid, size_t h_minfree, size_t v_align, size_t v_minfree, size_t r_align)
Leave define mode with performance tuning.
EXTERNL int nc_inq_ndims(int ncid, int *ndimsp)
Find the number of dimensions.
int nc_get_att_ulonglong(int ncid, int varid, const char *name, unsigned long long *value)
Get an attribute.
int nc_put_att_ushort(int ncid, int varid, const char *name, nc_type xtype, size_t len, const unsigned short *value)
Write an attribute.
EXTERNL int nc_rename_dim(int ncid, int dimid, const char *name)
Rename a dimension.
int nc_get_var1_string(int ncid, int varid, const size_t *indexp, char **ip)
Read a single datum from a variable.
int nc_put_var_uint(int ncid, int varid, const unsigned int *op)
Write an entire variable with one call.
int nc_put_vars_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const long long *op)
Write a strided array of values to a variable.
int nc_put_vara_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, const long long *op)
Write an array of values to a variable.
int nc_put_var_ulonglong(int ncid, int varid, const unsigned long long *op)
Write an entire variable with one call.
int nc_put_varm_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const unsigned short *op)
Write a mapped array of values to a variable.
int nc_put_vars_int(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const int *op)
Write a strided array of values to a variable.
int nc_get_var_long(int ncid, int varid, long *ip)
Read an entire variable in one call.
int nc_get_varm_schar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, signed char *ip)
Read a mapped array from a variable.
int nc_put_vars_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const unsigned char *op)
Write a strided array of values to a variable.
int nc_put_vars_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const unsigned short *op)
Write a strided array of values to a variable.
int nc_put_var_schar(int ncid, int varid, const signed char *op)
Write an entire variable with one call.
EXTERNL int nc_free_vlens(size_t len, nc_vlen_t vlens[])
Free an array of vlens given the number of elements and an array.
int nc_put_vara_double(int ncid, int varid, const size_t *startp, const size_t *countp, const double *op)
Write an array of values to a variable.
int nc_put_var_int(int ncid, int varid, const int *op)
Write an entire variable with one call.
int nc_put_var1_uchar(int ncid, int varid, const size_t *indexp, const unsigned char *op)
Write one datum.
int nc_put_vara_float(int ncid, int varid, const size_t *startp, const size_t *countp, const float *op)
Write an array of values to a variable.
EXTERNL int nc_put_var(int ncid, int varid, const void *op)
Write an entire variable with one call.
int nc_put_var1_ushort(int ncid, int varid, const size_t *indexp, const unsigned short *op)
Write one datum.
EXTERNL int nc_inq_var_chunking(int ncid, int varid, int *storagep, size_t *chunksizesp)
This is a wrapper for nc_inq_var_all().
EXTERNL int nc_put_vara(int ncid, int varid, const size_t *startp, const size_t *countp, const void *op)
Write an array of values to a variable.
int nc_get_vars_double(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, double *ip)
Read a strided array from a variable.
EXTERNL int nc_insert_array_compound(int ncid, nc_type xtype, const char *name, size_t offset, nc_type field_typeid, int ndims, const int *dim_sizes)
Insert a named array field into a compound type.
EXTERNL int nc_inq_dim(int ncid, int dimid, char *name, size_t *lenp)
Find the name and length of a dimension.
EXTERNL int nc_inq_varndims(int ncid, int varid, int *ndimsp)
Learn how many dimensions are associated with a variable.
int nc_get_var_schar(int ncid, int varid, signed char *ip)
Read an entire variable in one call.
EXTERNL int nc_inq_compound_fielddim_sizes(int ncid, nc_type xtype, int fieldid, int *dim_sizes)
Get information about one of the fields of a compound type.
int nc_put_var1_double(int ncid, int varid, const size_t *indexp, const double *op)
Write one datum.
int nc_get_att_short(int ncid, int varid, const char *name, short *value)
Get an attribute.
EXTERNL int nc_inq_format(int ncid, int *formatp)
Inquire about the binary format of a netCDF file as presented by the API.
int nc_put_att_ubyte(int ncid, int varid, const char *name, nc_type xtype, size_t len, const unsigned char *value)
Write an attribute.
EXTERNL int nc_inq_enum(int ncid, nc_type xtype, char *name, nc_type *base_nc_typep, size_t *base_sizep, size_t *num_membersp)
Learn about a user-define enumeration type.
EXTERNL int nc_put_varm(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const void *op)
Write a mapped array of values to a variable.
int nc_put_vars_short(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const short *op)
Write a strided array of values to a variable.
EXTERNL int nc_inq(int ncid, int *ndimsp, int *nvarsp, int *nattsp, int *unlimdimidp)
Inquire about a file or group.
EXTERNL int nc_get_varm(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, void *ip)
Read a mapped array from a variable.
EXTERNL int nc_def_opaque(int ncid, size_t size, const char *name, nc_type *xtypep)
Create an opaque type.
int nc_type
The nc_type type is just an int.
int nc_put_varm_int(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const int *op)
Write a mapped array of values to a variable.
int nc_get_att_uint(int ncid, int varid, const char *name, unsigned int *value)
Get an attribute.
int nc_get_vara_string(int ncid, int varid, const size_t *startp, const size_t *countp, char **ip)
Read an array of values from a variable.
EXTERNL int nc_put_vars(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const void *op)
Write a strided array of values to a variable.
EXTERNL int nc_inq_compound_name(int ncid, nc_type xtype, char *name)
Learn the name of a compound type.
int nc_put_var_string(int ncid, int varid, const char **op)
Write an entire variable with one call.
int nc_put_att_schar(int ncid, int varid, const char *name, nc_type xtype, size_t len, const signed char *value)
Write an attribute.
int nc_put_vara_short(int ncid, int varid, const size_t *startp, const size_t *countp, const short *op)
Write an array of values to a variable.
EXTERNL int nc_inq_attlen(int ncid, int varid, const char *name, size_t *lenp)
Find the length of an attribute.
int nc_put_vara_uint(int ncid, int varid, const size_t *startp, const size_t *countp, const unsigned int *op)
Write an array of values to a variable.
EXTERNL int nc_inq_format_extended(int ncid, int *formatp, int *modep)
Obtain more detailed (vis-a-vis nc_inq_format) format information about an open dataset.
int nc_put_att_int(int ncid, int varid, const char *name, nc_type xtype, size_t len, const int *value)
Write an attribute.
int nc_put_varm_short(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const short *op)
Write a mapped array of values to a variable.
EXTERNL int nc_put_att_text(int ncid, int varid, const char *name, size_t len, const char *op)
Write a text attribute.
int nc_put_var_ubyte(int ncid, int varid, const unsigned char *op)
Write an entire variable with one call.
int nc_put_vars_float(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const float *op)
Write a strided array of values to a variable.
int nc_put_vara_string(int ncid, int varid, const size_t *startp, const size_t *countp, const char **op)
Write an array of values to a variable.
EXTERNL int nc_set_var_chunk_cache(int ncid, int varid, size_t size, size_t nelems, float preemption)
EXTERNL int nc_inq_natts(int ncid, int *nattsp)
Find number of global or group attributes.
EXTERNL int nc_rename_var(int ncid, int varid, const char *name)
Rename a variable.
int nc_put_att_short(int ncid, int varid, const char *name, nc_type xtype, size_t len, const short *value)
Write an attribute.
EXTERNL int nc_del_att(int ncid, int varid, const char *name)
Delete an attribute.
int nc_get_var1_longlong(int ncid, int varid, const size_t *indexp, long long *ip)
Read a single datum from a variable.
int nc_put_vara_text(int ncid, int varid, const size_t *startp, const size_t *countp, const char *op)
Write an array of values to a variable.
int nc_put_var1_float(int ncid, int varid, const size_t *indexp, const float *op)
Write one datum.
EXTERNL int nc_inq_vlen(int ncid, nc_type xtype, char *name, size_t *datum_sizep, nc_type *base_nc_typep)
Learn about a VLEN type.
EXTERNL int nc_close(int ncid)
Close an open netCDF dataset.
int nc_put_var_longlong(int ncid, int varid, const long long *op)
Write an entire variable with one call.
int nc_get_varm_int(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, int *ip)
Read a mapped array from a variable.
int nc_get_vars_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, long long *ip)
Read a strided array from a variable.
int nc_put_vara_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, const unsigned char *op)
Write an array of values to a variable.
EXTERNL int nc_inq_dimlen(int ncid, int dimid, size_t *lenp)
Find the length of a dimension.
int nc_get_att_string(int ncid, int varid, const char *name, char **value)
Get an attribute.
EXTERNL int nc_inq_compound_field(int ncid, nc_type xtype, int fieldid, char *name, size_t *offsetp, nc_type *field_typeidp, int *ndimsp, int *dim_sizesp)
Get information about one of the fields of a compound type.
int nc_put_varm_text(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const char *op)
Write a mapped array of values to a variable.
int nc_put_var1_int(int ncid, int varid, const size_t *indexp, const int *op)
Write one datum.
int nc_get_vara_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, unsigned short *ip)
Read an array of values from a variable.
EXTERNL int nc_get_var(int ncid, int varid, void *ip)
Read an entire variable in one call.
EXTERNL int nc_get_att(int ncid, int varid, const char *name, void *ip)
Get an attribute of any type.
int nc_get_var_int(int ncid, int varid, int *ip)
Read an entire variable in one call.
int nc_put_varm_string(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const char **op)
Write a mapped array of values to a variable.
int nc_get_vara_short(int ncid, int varid, const size_t *startp, const size_t *countp, short *ip)
Read an array of values from a variable.
EXTERNL int nc_inq_compound_fieldtype(int ncid, nc_type xtype, int fieldid, nc_type *field_typeidp)
Get information about one of the fields of a compound type.
int nc_get_var_ushort(int ncid, int varid, unsigned short *ip)
Read an entire variable in one call.
EXTERNL int nc_def_compound(int ncid, size_t size, const char *name, nc_type *typeidp)
Create a compound type.
EXTERNL int nc_get_att_text(int ncid, int varid, const char *name, char *ip)
Get an attribute.
int nc_get_att_longlong(int ncid, int varid, const char *name, long long *value)
Get an attribute.
int nc_get_var_double(int ncid, int varid, double *ip)
Read an entire variable in one call.
int nc_put_varm_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const unsigned long long *op)
Write a mapped array of values to a variable.
int nc_get_vara_float(int ncid, int varid, const size_t *startp, const size_t *countp, float *ip)
Read an array of values from a variable.
This is the type of arrays of vlens.
int nc_put_att_long(int ncid, int varid, const char *name, nc_type xtype, size_t len, const long *value)
Write an attribute.
int nc_put_vara_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, const unsigned short *op)
Write an array of values to a variable.
int nc_get_varm_uint(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, unsigned int *ip)
Read a mapped array from a variable.
int nc_get_var_string(int ncid, int varid, char **ip)
Read an entire variable in one call.
int nc_put_var1_longlong(int ncid, int varid, const size_t *indexp, const long long *op)
Write one datum.
int nc_get_var1_ubyte(int ncid, int varid, const size_t *indexp, unsigned char *ip)
Read a single datum from a variable.
int nc_get_var1_uchar(int ncid, int varid, const size_t *indexp, unsigned char *ip)
Read a single datum from a variable.
EXTERNL int nc_get_var1(int ncid, int varid, const size_t *indexp, void *ip)
Read a single datum from a variable.
EXTERNL int nc_inq_compound(int ncid, nc_type xtype, char *name, size_t *sizep, size_t *nfieldsp)
Learn about a compound type.
int nc_get_vara_int(int ncid, int varid, const size_t *startp, const size_t *countp, int *ip)
Read an array of values from a variable.
EXTERNL int nc_inq_var_szip(int ncid, int varid, int *options_maskp, int *pixels_per_blockp)
Learn the szip settings of a variable.
int nc_put_vara_long(int ncid, int varid, const size_t *startp, const size_t *countp, const long *op)
Write an array of values to a variable.
EXTERNL int nc_inq_var_fletcher32(int ncid, int varid, int *fletcher32p)
Learn the checksum settings for a variable.
int nc_get_var1_uint(int ncid, int varid, const size_t *indexp, unsigned int *ip)
Read a single datum from a variable.
void * p
Pointer to VL data.
int nc_get_att_float(int ncid, int varid, const char *name, float *value)
Get an attribute.
int nc_get_vara_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, long long *ip)
Read an array of values from a variable.
int nc_put_varm_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const long long *op)
Write a mapped array of values to a variable.
EXTERNL int nc_put_var1(int ncid, int varid, const size_t *indexp, const void *op)
Write one datum.
int nc_put_att_uchar(int ncid, int varid, const char *name, nc_type xtype, size_t len, const unsigned char *value)
Write an attribute.
int nc_get_vara_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, unsigned long long *ip)
Read an array of values from a variable.
int nc_get_att_uchar(int ncid, int varid, const char *name, unsigned char *value)
Get an attribute.
int nc_get_vars_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, unsigned char *ip)
Read a strided array from a variable.
int nc_get_var_text(int ncid, int varid, char *ip)
Read an entire variable in one call.
EXTERNL int nc_inq_compound_nfields(int ncid, nc_type xtype, size_t *nfieldsp)
Learn the number of fields in a compound type.
int nc_get_varm_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, unsigned char *ip)
Read a mapped array from a variable.
EXTERNL int nc_inq_compound_fieldndims(int ncid, nc_type xtype, int fieldid, int *ndimsp)
Get information about one of the fields of a compound type.
int nc_get_vars_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, unsigned long long *ip)
Read a strided array from a variable.
int nc_get_vars_int(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, int *ip)
Read a strided array from a variable.
int nc_get_vara_ubyte(int ncid, int varid, const size_t *startp, const size_t *countp, unsigned char *ip)
Read an array of values from a variable.
int nc_get_var1_float(int ncid, int varid, const size_t *indexp, float *ip)
Read a single datum from a variable.
EXTERNL int nc_set_fill(int ncid, int fillmode, int *old_modep)
Change the fill-value mode to improve write performance.
int nc_get_vara_text(int ncid, int varid, const size_t *startp, const size_t *countp, char *ip)
Read an array of values from a variable.
int nc_put_att_uint(int ncid, int varid, const char *name, nc_type xtype, size_t len, const unsigned int *value)
Write an attribute.
int nc_get_vara_schar(int ncid, int varid, const size_t *startp, const size_t *countp, signed char *ip)
Read an array of values from a variable.
int nc_put_var1_schar(int ncid, int varid, const size_t *indexp, const signed char *op)
Write one datum.
EXTERNL int nc_inq_vartype(int ncid, int varid, nc_type *xtypep)
Learn the type of a variable.
EXTERNL int nc_put_att(int ncid, int varid, const char *name, nc_type xtype, size_t len, const void *op)
Write an attribute.
int nc_get_vars_float(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, float *ip)
Read a strided array from a variable.
EXTERNL int nc_inq_type(int ncid, nc_type xtype, char *name, size_t *size)
Inquire about a type.
int nc_put_att_ulonglong(int ncid, int varid, const char *name, nc_type xtype, size_t len, const unsigned long long *value)
Write an attribute.
EXTERNL int nc_free_vlen(nc_vlen_t *vl)
Free memory in a VLEN object.
int nc_put_vara_int(int ncid, int varid, const size_t *startp, const size_t *countp, const int *op)
Write an array of values to a variable.
EXTERNL int nc_free_string(size_t len, char **data)
Free string space allocated by the library.
int nc_put_varm_schar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const signed char *op)
Write a mapped array of values to a variable.
EXTERNL int nc_inq_compound_fieldindex(int ncid, nc_type xtype, const char *name, int *fieldidp)
Learn the Index of a Named Field in a Compound Type.
EXTERNL int nc_inq_compound_fieldoffset(int ncid, nc_type xtype, int fieldid, size_t *offsetp)
Get information about one of the fields of a compound type.
int nc_get_var_ubyte(int ncid, int varid, unsigned char *ip)
Read an entire variable in one call.
EXTERNL int nc_inq_varname(int ncid, int varid, char *name)
Learn the name of a variable.
int nc_get_var_longlong(int ncid, int varid, long long *ip)
Read an entire variable in one call.
int nc_put_var1_ulonglong(int ncid, int varid, const size_t *indexp, const unsigned long long *op)
Write one datum.
int nc_put_varm_double(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const double *op)
Write a mapped array of values to a variable.
int nc_get_att_long(int ncid, int varid, const char *name, long *value)
Get an attribute.
int nc_get_vars_short(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, short *ip)
Read a strided array from a variable.
int nc_get_var1_ushort(int ncid, int varid, const size_t *indexp, unsigned short *ip)
Read a single datum from a variable.
size_t len
Length of VL data (in base type units)
EXTERNL int nc__create(const char *path, int cmode, size_t initialsz, size_t *chunksizehintp, int *ncidp)
Create a netCDF file with some extra parameters controlling classic file cacheing.
int nc_get_varm_text(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, char *ip)
Read a mapped array from a variable.
int nc_put_var1_short(int ncid, int varid, const size_t *indexp, const short *op)
Write one datum.
EXTERNL int nc_inq_compound_fieldname(int ncid, nc_type xtype, int fieldid, char *name)
Get information about one of the fields of a compound type.
int nc_get_var1_schar(int ncid, int varid, const size_t *indexp, signed char *ip)
Read a single datum from a variable.
int nc_put_var_double(int ncid, int varid, const double *op)
Write an entire variable with one call.
int nc_get_vars_schar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, signed char *ip)
Read a strided array from a variable.
EXTERNL int nc_insert_enum(int ncid, nc_type xtype, const char *name, const void *value)
Insert a named member into a enum type.
int nc_get_vars_long(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, long *ip)
Read a strided array from a variable.
EXTERNL int nc_inq_varid(int ncid, const char *name, int *varidp)
Find the ID of a variable, from the name.
EXTERNL int nc_insert_compound(int ncid, nc_type xtype, const char *name, size_t offset, nc_type field_typeid)
Insert a named field into a compound type.
int nc_get_vars_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, unsigned short *ip)
Read a strided array from a variable.
EXTERNL int nc_inq_dimid(int ncid, const char *name, int *idp)
Find the ID of a dimension from the name.
int nc_put_varm_long(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const long *op)
Write a mapped array of values to a variable.
int nc_get_vara_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, unsigned char *ip)
Read an array of values from a variable.
int nc_get_var_float(int ncid, int varid, float *ip)
Read an entire variable in one call.
int nc_get_var1_short(int ncid, int varid, const size_t *indexp, short *ip)
Read a single datum from a variable.
EXTERNL int nc_get_vars(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, void *ip)
Read a strided array from a variable.
int nc_put_att_float(int ncid, int varid, const char *name, nc_type xtype, size_t len, const float *value)
Write an attribute.
EXTERNL int nc_inq_unlimdim(int ncid, int *unlimdimidp)
Find the ID of the unlimited dimension.
int nc_put_var_text(int ncid, int varid, const char *op)
Write an entire variable with one call.
EXTERNL int nc_inq_enum_member(int ncid, nc_type xtype, int idx, char *name, void *value)
Learn about a about a member of an enum type.
int nc_get_var_short(int ncid, int varid, short *ip)
Read an entire variable in one call.
int nc_put_varm_uint(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const unsigned int *op)
Write a mapped array of values to a variable.
int nc_get_var1_ulonglong(int ncid, int varid, const size_t *indexp, unsigned long long *ip)
Read a single datum from a variable.
int nc_get_att_schar(int ncid, int varid, const char *name, signed char *value)
Get an attribute.
int nc_put_att_longlong(int ncid, int varid, const char *name, nc_type xtype, size_t len, const long long *value)
Write an attribute.
int nc_put_var1_text(int ncid, int varid, const size_t *indexp, const char *op)
Write one datum.
int nc_put_vara_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, const unsigned long long *op)
Write an array of values to a variable.
int nc_put_var_float(int ncid, int varid, const float *op)
Write an entire variable with one call.
EXTERNL int nc_inq_enum_ident(int ncid, nc_type xtype, long long value, char *identifier)
Get the name which is associated with an enum member value.
int nc_put_vars_text(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const char *op)
Write a strided array of values to a variable.
int nc_get_var1_double(int ncid, int varid, const size_t *indexp, double *ip)
Read a single datum from a variable.
int nc_put_var1_long(int ncid, int varid, const size_t *indexp, const long *op)
Write one datum.
int nc_put_var_ushort(int ncid, int varid, const unsigned short *op)
Write an entire variable with one call.
EXTERNL int nc_inq_var_deflate(int ncid, int varid, int *shufflep, int *deflatep, int *deflate_levelp)
Learn the storage and deflate settings for a variable.
EXTERNL int nc_inq_unlimdims(int ncid, int *nunlimdimsp, int *unlimdimidsp)
Return number and list of unlimited dimensions.
EXTERNL int nc_inq_var(int ncid, int varid, char *name, nc_type *xtypep, int *ndimsp, int *dimidsp, int *nattsp)
Learn about a variable.
int nc_put_vars_schar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const signed char *op)
Write a strided array of values to a variable.
int nc_get_var_uchar(int ncid, int varid, unsigned char *ip)
Read an entire variable in one call.
EXTERNL int nc_inq_path(int ncid, size_t *pathlen, char *path)
Get the file pathname (or the opendap URL) which was used to open/create the ncid's file...
int nc_put_vars_long(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const long *op)
Write a strided array of values to a variable.
int nc_get_var1_long(int ncid, int varid, const size_t *indexp, long *ip)
Read a single datum from a variable.
int nc_get_varm_long(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, long *ip)
Read a mapped array from a variable.
EXTERNL int nc_put_att_string(int ncid, int varid, const char *name, size_t len, const char **op)
Write a string attribute.
EXTERNL int nc_def_vlen(int ncid, const char *name, nc_type base_typeid, nc_type *xtypep)
Use this function to define a variable length array type.
EXTERNL int nc_open(const char *path, int mode, int *ncidp)
Open an existing netCDF file.
EXTERNL int nc_inq_varnatts(int ncid, int varid, int *nattsp)
Learn how many attributes are associated with a variable.
int nc_get_att_ubyte(int ncid, int varid, const char *name, unsigned char *value)
Get an attribute.
int nc_put_vars_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const unsigned long long *op)
Write a strided array of values to a variable.
EXTERNL int nc_inq_compound_size(int ncid, nc_type xtype, size_t *sizep)
Learn the size of a compound type.
EXTERNL int nc_enddef(int ncid)
Leave define mode.
int nc_put_var1_uint(int ncid, int varid, const size_t *indexp, const unsigned int *op)
Write one datum.
int nc_get_att_int(int ncid, int varid, const char *name, int *value)
Get an attribute.
int nc_get_att_double(int ncid, int varid, const char *name, double *value)
Get an attribute.
EXTERNL const char * nc_strerror(int ncerr)
Given an error number, return an error message.
EXTERNL int nc_inq_user_type(int ncid, nc_type xtype, char *name, size_t *size, nc_type *base_nc_typep, size_t *nfieldsp, int *classp)
Learn about a user defined type.
EXTERNL int nc_inq_attid(int ncid, int varid, const char *name, int *idp)
Find an attribute ID.
int nc_get_var1_int(int ncid, int varid, const size_t *indexp, int *ip)
Read a single datum from a variable.
int nc_put_var_uchar(int ncid, int varid, const unsigned char *op)
Write an entire variable with one call.
int nc_get_varm_ushort(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, unsigned short *ip)
Read a mapped array from a variable.
int nc_put_var_short(int ncid, int varid, const short *op)
Write an entire variable with one call.
EXTERNL int nc_inq_var_fill(int ncid, int varid, int *no_fill, void *fill_valuep)
Learn the fill mode of a variable.
int nc_put_varm_float(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const float *op)
Write a mapped array of values to a variable.
int nc_get_varm_string(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, char **ip)
Read a mapped array from a variable.
int nc_get_varm_double(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, double *ip)
Read a mapped array from a variable.
EXTERNL int nc_sync(int ncid)
Synchronize an open netcdf dataset to disk.
EXTERNL int nc_get_vara(int ncid, int varid, const size_t *startp, const size_t *countp, void *ip)
Read an array of values from a variable.
EXTERNL int nc_create(const char *path, int cmode, int *ncidp)
Create a new netCDF file.
int nc_put_var1_ubyte(int ncid, int varid, const size_t *indexp, const unsigned char *op)
Write one datum.
int nc_put_varm_uchar(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, const unsigned char *op)
Write a mapped array of values to a variable.
int nc_get_vara_long(int ncid, int varid, const size_t *startp, const size_t *countp, long *ip)
Read an array of values from a variable.
int nc_get_varm_longlong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, long long *ip)
Read a mapped array from a variable.
int nc_put_vars_string(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const char **op)
Write a strided array of values to a variable.
int nc_get_vars_string(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, char **ip)
Read a strided array from a variable.
EXTERNL int nc_inq_attname(int ncid, int varid, int attnum, char *name)
Find the name of an attribute.
int nc_get_vars_uint(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, unsigned int *ip)
Read a strided array from a variable.
EXTERNL int nc_inq_typeid(int ncid, const char *name, nc_type *typeidp)
Find a type by name.
int nc_get_varm_ulonglong(int ncid, int varid, const size_t *startp, const size_t *countp, const ptrdiff_t *stridep, const ptrdiff_t *imapp, unsigned long long *ip)
Read a mapped array from a variable.