gridspec_api/data/nccf_put_struct_data.c

00001 
00007 #include <stdio.h>
00008 #include <stdlib.h>
00009 #include <string.h>
00010 
00011 #include <netcdf.h>
00012 #include "nccf_data.h"
00013 
00014 int nccf_put_struct_data(int ncid, int dataid) {
00015 
00016   int status = NC_NOERR;
00017   struct nccf_struct_data_type *self;
00018   self = nccf_li_find(&CFLIST_STRUCTURED_DATA, dataid);
00019 
00020   // Write data to file
00021   if( self->numRecords == 0 ){
00022     status = nccf_writeListOfVars(ncid, 1, self->dataVar);
00023   } else {
00024     status = nccf_writeListOfVarData(ncid, 1, self->dataVar);
00025   }
00026 
00027   self->numRecords++;
00028 
00029   return status;
00030 }
 All Classes Files Functions Defines

Generated on Tue Mar 1 2011 06:36:59 for libCF. LibCF is a Unidata library.