Ignore:
Timestamp:
05/04/07 16:11:02 (13 years ago)
Author:
domlowe
Message:

storage descriptor separated from feature collection

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI02-CSML/trunk/csml/API/csmlContainer.py

    r2385 r2387  
    5151        #append NetCDF file path to containerContents 
    5252        self.ncfiles.append(ncfile) 
     53     
     54    def attachDescriptor(self, descriptor): 
     55        self.sd.append(descriptor) 
    5356 
    54     def add(self, featureplusfile): 
    55         #featureplusfile should be a feature, and a filepath to the netcdf file  
    56         self.appendFeature(featureplusfile[0]) 
    57         self.attachNetCDFFile(featureplusfile[1]) 
     57    def add(self, featureplusfileplusdescriptor): 
     58        #featureplusfileplusdescriptor should be a feature, and a filepath to the netcdf file, and a storage descriptor 
     59        self.appendFeature(featureplusfileplusdescriptor[0]) 
     60        self.attachNetCDFFile(featureplusfileplusdescriptor[1]) 
     61        self.attachDescriptor(featureplusfileplusdescriptor[2]) 
    5862         
    5963    
    6064    def getContents(self): 
    61         self.ds.storageDescriptor=self.sd 
     65        self.ds.storageDescriptor=csml.parser.CSMLStorageDescriptor(descriptors=self.sd) 
    6266        self.ds.featureCollection=csml.parser.CSMLFeatureCollection(featureMembers=self.fm) 
    6367        self.ds.featureCollection.id=csml.csmllibs.csmlextra.getRandomID() 
Note: See TracChangeset for help on using the changeset viewer.