App Engine Python SDK  v1.6.9 rev.445
The Python runtime is available as an experimental Preview feature.
Public Member Functions | List of all members
google.appengine.api.validation.ValidatedBase Class Reference
Inheritance diagram for google.appengine.api.validation.ValidatedBase:
google.appengine.api.validation.Validated google.appengine.api.validation.ValidatedDict google.appengine.api.backendinfo.BackendEntry google.appengine.api.backendinfo.BackendInfoExternal google.appengine.api.client_deployinfo.ClientDeployInfoExternal google.appengine.api.client_deployinfo.Request google.appengine.api.conf.YAMLConfiguration google.appengine.api.croninfo.CronEntry google.appengine.api.croninfo.CronInfoExternal google.appengine.api.dispatchinfo.DispatchEntry google.appengine.api.dispatchinfo.DispatchInfoExternal google.appengine.api.dosinfo.BlacklistEntry google.appengine.api.dosinfo.DosInfoExternal google.appengine.api.pagespeedinfo.PagespeedEntry google.appengine.api.queueinfo.Acl google.appengine.api.queueinfo.QueueEntry google.appengine.api.queueinfo.QueueInfoExternal google.appengine.api.queueinfo.RetryParameters google.appengine.api.conf._ParameterDict

Public Member Functions

def GetValidator
 
def SetMultiple
 
def Set
 
def CheckInitialized
 
def ToDict
 
def ToYAML
 

Detailed Description

Base class for all validated objects.

Member Function Documentation

def google.appengine.api.validation.ValidatedBase.CheckInitialized (   self)
Checks that all required fields are initialized.

This function is called after all attributes have been checked to
verify any higher level constraints, for example ensuring all required
attributes are present.

Subclasses should override this function and raise an exception for
any errors.
def google.appengine.api.validation.ValidatedBase.GetValidator (   self,
  key 
)
Safely get the Validator corresponding to the given key.

This function should be overridden by subclasses

Args:
  key: The attribute or item to get a validator for.

Returns:
  Validator associated with key or attribute.

Raises:
  ValidationError: if the requested key is illegal.
def google.appengine.api.validation.ValidatedBase.Set (   self,
  key,
  value 
)
Set a single value on Validated instance.

This method should be overridded by sub-classes.

This method can only be used to assign validated attributes/items.

Args:
  key: The name of the attributes
  value: The value to set

Raises:
  ValidationError: when no validated attribute exists on class.
def google.appengine.api.validation.ValidatedBase.SetMultiple (   self,
  attributes 
)
Set multiple values on Validated instance.

All attributes will be validated before being set.

Args:
  attributes: A dict of attributes/items to set.

Raises:
  ValidationError: when no validated attribute exists on class.
def google.appengine.api.validation.ValidatedBase.ToDict (   self)
Convert ValidatedBase object to a dictionary.

Recursively traverses all of its elements and converts everything to
simplified collections.

Subclasses should override this method.

Returns:
  A dictionary mapping all attributes to simple values or collections.
def google.appengine.api.validation.ValidatedBase.ToYAML (   self)
Print validated object as simplified YAML.

Returns:
  Object as a simplified YAML string compatible with parsing using the
  SafeLoader.

The documentation for this class was generated from the following file: