def _setg_type(self, value): value = VCS_validation_functions.checkString(self, 'g_type', value) value = value.lower() if not value in vcs.elements and value != "text": raise ValueError, "invalid g_type '%s' must be one of: %s " % ( value, vcs.elements.keys()) self._g_type = value
def _setg_type(self, value): value = VCS_validation_functions.checkString(self, 'g_type', value) value = value.lower() if not value in ('boxfill', 'isofill', 'isoline', 'outfill', 'outline', 'continents', 'scatter', 'vector', 'xvsy', 'xyvsy', 'yxvsx', 'taylordiagram', 'meshfill'): raise ValueError, "g_type must be one of: ('boxfill', 'isofill', 'isoline', 'outfill', 'outline', 'continents', 'scatter', 'vector', 'xvsy', 'xyvsy', 'yxvsx','taylordiagram','meshfill')" setmember(self, 'g_type', value)
def _setg_type(self, value): value = VCS_validation_functions.checkString(self, 'g_type', value) value = value.lower() if value not in vcs.elements and value != "text": raise ValueError( "invalid g_type '%s' must be one of: %s " % (value, vcs.elements.keys())) self._g_type = value
def _setg_type(self, value): import vcsaddons value = VCS_validation_functions.checkString(self, 'g_type', value) value = value.lower() if value not in vcs.elements and value != "text" and value not in vcsaddons.gms: raise ValueError("invalid g_type '%s' must be one of: %s " % (value, vcs.elements.keys())) self._g_type = value
def _setstring(self,value): if isinstance(value,str): value = [value,] elif isinstance(value,(list,tuple)): vals = [] for v in value: vals.append(VCS_validation_functions.checkString(self,'string',v)) value = vals else: raise ValueError, 'Must be a string or a list of strings.' setTtmember(self,'string',value)
def _setg_type(self, value): value = VCS_validation_functions.checkString(self, "g_type", value) value = value.lower() if not value in ( "boxfill", "isofill", "isoline", "outfill", "outline", "continents", "scatter", "vector", "xvsy", "xyvsy", "yxvsx", "taylordiagram", "meshfill", ): raise ValueError, "g_type must be one of: ('boxfill', 'isofill', 'isoline', 'outfill', 'outline', 'continents', 'scatter', 'vector', 'xvsy', 'xyvsy', 'yxvsx','taylordiagram','meshfill')" setmember(self, "g_type", value)
def _settemplate(self,value): value = VCS_validation_functions.checkString(self,'template',value) setmember(self,'template',value)
def _settemplate_origin(self,value): value = VCS_validation_functions.checkString(self,'_template_origin',value) setmember(self,'_template_origin',value)
def _setformat(self, value): self._format = VCS_validation_functions.checkString( self, "format", value)
def _setg_name(self,value): value = VCS_validation_functions.checkString(self,'g_name',value) setmember(self,'g_name',value)
def _settemplate(self, value): self._template = VCS_validation_functions.checkString( self, 'template', value)
def _settemplate_origin(self, value): self.__template_origin = VCS_validation_functions.checkString( self, '_template_origin', value)
def _setg_name(self, value): self._g_name = VCS_validation_functions.checkString( self, 'g_name', value)
def _setformat(self,value): self._format = VCS_validation_functions.checkString(self,"format",value)