Ignore:
Timestamp:
26/05/06 12:31:12 (13 years ago)
Author:
domlowe
Message:

fixed API imports across all modules

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI02-CSML/trunk/parser/API/parser_api.py

    r1025 r1027  
    22 
    33#import parser from parent directory 
    4 import os, sys 
    5 currentPath=os.getcwd() 
    6 parserPath=os.sep.join(currentPath.split(os.sep)[:-1]) 
    7 sys.path.append(parserPath) #append the parser path to sys.path  
    8 try: 
    9     from Parser import * 
    10     import parser_extra 
    11 except: 
    12     print 'Could not import CSML Parser. Make sure the Parser code is in parent directory.' 
    13     sys.exit() 
    14  
    15 import ops_Dataset 
    16 import ops_AbstractFeature 
    17 import ops_PointFeature 
    18 import ops_ProfileFeature 
    19  
     4# import os, sys 
     5# currentPath=os.getcwd() 
     6# parserPath=os.sep.join(currentPath.split(os.sep)[:-1]) 
     7# sys.path.append(parserPath) #append the parser path to sys.path  
     8# try: 
     9#     from Parser import * 
     10#     import parser_extra 
     11# except: 
     12#     print 'Could not import CSML Parser. Make sure the Parser code is in parent directory.' 
     13#     sys.exit() 
     14#  
     15# import ops_Dataset 
     16# import ops_AbstractFeature 
     17# import ops_PointFeature 
     18# import ops_PointSeriesFeature 
     19# import ops_ProfileFeature 
     20# import ops_ProfileSeriesFeature 
     21# import ops_GridFeature 
     22# import ops_GridSeriesFeature 
     23# import ops_TrajectoryFeature 
    2024 
    2125#Assign methods  .. hmmm perhaps a loop needed here!! 
     
    2529Dataset.getFeatureList=ops_Dataset.getFeatureList 
    2630Dataset.getFeature=ops_Dataset.getFeature 
     31Dataset.getFileExtract=ops_Dataset.getFileExtract 
    2732 
    2833 
    2934#AbstractFeature methods: 
    3035AbstractFeature.testmethod=ops_AbstractFeature.testmethod 
     36AbstractFeature.getAllowedSubsettings=ops_AbstractFeature.getAllowedSubsettings 
    3137 
    3238#PointFeature methods: 
    3339PointFeature.testmethod=ops_PointFeature.testmethod 
     40#PointFeature.getAllowedSubsettings=ops_PointFeature.getAllowedSubsettings 
    3441 
    3542#PointSeriesFeature methods: 
    3643PointSeriesFeature.testmethod=ops_PointSeriesFeature.testmethod 
     44#PointSeriesFeature.getAllowedSubsettings=ops_PointSeriesFeature.getAllowedSubsettings 
    3745 
    3846#ProfileFeature methods: 
    3947ProfileFeature.testmethod=ops_ProfileFeature.testmethod 
     48#ProfileFeature.getAllowedSubsettings=ops_ProfileFeature.getAllowedSubsettings 
    4049 
    4150#ProfileSeriesFeature methods: 
    4251ProfileSeriesFeature.testmethod=ops_ProfileSeriesFeature.testmethod 
     52#ProfileSeriesFeature.getAllowedSubsettings=ops_ProfileSeriesFeature.getAllowedSubsettings 
    4353 
    44 #Grid methods: 
    45 Grid.testmethod=ops_GridFeature.testmethod 
     54#GridFeature methods: 
     55GridFeature.testmethod=ops_GridFeature.testmethod 
     56#GridFeature.getAllowedSubsettings=ops_GridFeature.getAllowedSubsettings 
    4657 
    47 #GridSeries methods: 
    48 GridSeries.testmethod=ops_GridSeriesFeature.testmethod 
     58#GridSeriesFeature methods: 
     59GridSeriesFeature.testmethod=ops_GridSeriesFeature.testmethod 
     60GridSeriesFeature.getAllowedSubsettings=ops_GridSeriesFeature.getAllowedSubsettings 
     61GridSeriesFeature.getDomainReference=ops_GridSeriesFeature.getDomainReference 
    4962 
    50 #Trajectory methods: 
    51 Trajectory.testmethod=ops_TrajectoryFeature.testmethod 
     63#TrajectoryFeature methods: 
     64TrajectoryFeature.testmethod=ops_TrajectoryFeature.testmethod 
Note: See TracChangeset for help on using the changeset viewer.