Exemple #1
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   self._validateParameters(self.inventory)
   data = []
   units = []
   for x in self.inventory.data:
     if len(str(x).split("*")) > 1:
       xdim = self.parser.parse(str(x))
       data.append(float((xdim.value)))
       strDeriv = xdim._strDerivation()
       if len(strDeriv) > 0:
         units.append(xdim._strDerivation())
       else:
         units.append("none")
     else:
       data.append(float(x))
       units.append("none")
   values = []
   for v in self.inventory.values:
     values.append(v.lstrip().rstrip())
   self.setData(values, units, data)
   return
Exemple #2
0
 def __init__(self, name="uniformdb"):
   """
   Constructor.
   """
   SpatialDBObj.__init__(self, name)
   from pyre.units import parser
   self.parser = parser()
   return
Exemple #3
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   ModuleSimpleGridDB.filename(self, self.inventory.filename)
   ModuleSimpleGridDB.queryType(self, self._parseQueryString(self.inventory.queryType))
   return
Exemple #4
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   self.ioHandler(self.inventory.iohandler)
   self.queryType(self._parseQueryString(self.inventory.queryType))
   return
Exemple #5
0
 def _configure(self):
     """
 Set members based on inventory.
 """
     SpatialDBObj._configure(self)
     self.ioHandler(self.inventory.iohandler)
     self.queryType(self._parseQueryString(self.inventory.queryType))
     return
Exemple #6
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   ModuleSimpleGridDB.filename(self, self.inventory.filename)
   ModuleSimpleGridDB.queryType(self, self._parseQueryString(self.inventory.queryType))
   return
Exemple #7
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   self._validateParameters(self.inventory)
   self.dbA(self.inventory.dbA, self.inventory.namesA)
   self.dbB(self.inventory.dbB, self.inventory.namesB)
   return
Exemple #8
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   ModuleUserFunctionDB.coordsys(self, self.inventory.cs)
   for (name, fn, units,) in self.functions:
     ModuleUserFunctionDB.addValue(self, name, fn, units)
   return
Exemple #9
0
 def _configure(self):
     """
 Set members based on inventory.
 """
     SpatialDBObj._configure(self)
     self._validateParameters(self.inventory)
     self.dbA(self.inventory.dbA, self.inventory.namesA)
     self.dbB(self.inventory.dbB, self.inventory.namesB)
     return
Exemple #10
0
 def _configure(self):
     """
 Set members based on inventory.
 """
     SpatialDBObj._configure(self)
     self.label("SCEC CVM-H")
     self.dataDir(self.inventory.dataDir)
     self.minVs(self.inventory.minVs.value)
     self.squash(self.inventory.squash, self.inventory.squashLimit.value)
     return
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   self._validateParameters(self.inventory)
   dir = map(float, self.inventory.gravityDir)
   self.gravityDir(dir[0], dir[1], dir[2])
   self.gravityAcc(self.inventory.acceleration.value)
   return
Exemple #12
0
 def _configure(self):
     """
 Set members based on inventory.
 """
     SpatialDBObj._configure(self)
     self._validateParameters(self.inventory)
     dir = map(float, self.inventory.gravityDir)
     self.gravityDir(dir[0], dir[1], dir[2])
     self.gravityAcc(self.inventory.acceleration.value)
     return
Exemple #13
0
 def _configure(self):
   """
   Set members based on inventory.
   """
   SpatialDBObj._configure(self)
   self.label("SCEC CVM-H")
   self.dataDir(self.inventory.dataDir)
   self.minVs(self.inventory.minVs.value)
   self.squash(self.inventory.squash, self.inventory.squashLimit.value)
   return
Exemple #14
0
  def __init__(self, name="userfunctiondb"):
    """
    Constructor.
    """
    SpatialDBObj.__init__(self, name)

    # This data member should be initialized in derived classes.
    #
    # self.functions = [(name, pointer_to_queryfn, units)]
    self.functions = []
    return
Exemple #15
0
 def __init__(self, name="compositedb"):
     """
 Constructor.
 """
     SpatialDBObj.__init__(self, name)
     return
Exemple #16
0
 def __init__(self, name="compositedb"):
   """
   Constructor.
   """
   SpatialDBObj.__init__(self, name)
   return
Exemple #17
0
 def __init__(self, name="simpledb"):
   """
   Constructor.
   """
   SpatialDBObj.__init__(self, name)
   return
 def __init__(self, name="gravityfield"):
   """
   Constructor.
   """
   SpatialDBObj.__init__(self, name)
   return
Exemple #19
0
 def __init__(self, name="sceccvmh"):
   """
   Constructor.
   """
   SpatialDBObj.__init__(self, name)
   return
Exemple #20
0
 def __init__(self, name="sceccvmh"):
     """
 Constructor.
 """
     SpatialDBObj.__init__(self, name)
     return
Exemple #21
0
 def __init__(self, name="gravityfield"):
     """
 Constructor.
 """
     SpatialDBObj.__init__(self, name)
     return
Exemple #22
0
 def __init__(self, name="simpledb"):
     """
 Constructor.
 """
     SpatialDBObj.__init__(self, name)
     return