Package orm2 :: Module datatypes :: Class common_serial
[hide private]
[frames] | no frames]

Class common_serial

source code

object --+            
         |            
  property --+        
             |        
      datatype --+    
                 |    
           integer --+
                     |
                    common_serial

The common_serial datatype is an primary key integer column whoes value is supplied by the backend using its default mechanism. The default mechanism for each backend is defined by the adapter's datatype module (see there). The name of the common_serial column is alway 'id'.

This class used by some of the test cases to define data models that work on every backend.

Nested Classes [hide private]

Inherited from integer: python_class, sql_literal_class


Instance Methods [hide private]
  __init__(self)
  __init_dbclass__(self, dbclass, attribute_name)
This methods gets called by dbobject's metaclass.
  __set__(self, dbobj, value)
Set the attribute managed by this datatype class on instance to value.
  __set_from_result__(self, ds, dbobj, value)

Inherited from datatype: __convert__, __delete__, __get__, __select_after_insert__, __select_this_column__, __setattr__, add_widget, check_dbobj, data_attribute_name, isset, sql_literal, widget_specs

Inherited from property: __getattribute__, __new__

Inherited from object: __delattr__, __hash__, __reduce__, __reduce_ex__, __repr__, __str__


Class Variables [hide private]

Inherited from property: fdel, fget, fset


Properties [hide private]

Inherited from object: __class__


Method Details [hide private]

__init__(self)
(Constructor)

source code 
Overrides: datatype.__init__
(inherited documentation)

__init_dbclass__(self, dbclass, attribute_name)

source code 
This methods gets called by dbobject's metaclass. It supplies the db property with info about the class it belongs to and its attribute name.
Overrides: datatype.__init_dbclass__
(inherited documentation)

__set__(self, dbobj, value)

source code 
Set the attribute managed by this datatype class on instance to value. This will be called by Python on attribute assignment. The __set_from_result__ method does the same thing for data retrieved from the RDBMS. See below.
Overrides: datatype.__set__
(inherited documentation)

__set_from_result__(self, ds, dbobj, value)

source code 
None
Overrides: datatype.__set_from_result__