Package | com.memamsa.airdb |
Class | public dynamic class SchemaInfo |
Inheritance | SchemaInfo Modeler flash.utils.Proxy |
SchemaInfo
model maintains schema version information for
all the other models.
Uses Modeler
query and update methods to create and track
migration versions for all Modeler
sub-classes within the
application.
The schema for the SchemaInfo
class consists of a simple
property-value format, where
property => name of the table value => current schema version for that table
Method | Defined by | ||
---|---|---|---|
SchemaInfo(newrow:Object = null)
| SchemaInfo | ||
count():int
Count the total number of records in the table for this model.
| Modeler | ||
countAll(query:Object):int
Count the number of records matching specified query criteria
| Modeler | ||
create(values:Object = null):Boolean
Create a new record by combining field values in this instance with
the specified values.
| Modeler | ||
data(values:Object):void
Initialize this instance with specified field values, potentially for a
new record.
| Modeler | ||
find(keyvals:Object):Boolean
Check for the existence of records matching criteria specified in terms
of field names and associated values.
| Modeler | ||
findAll(query:Object, page:int = 1, perPage:int = 0):Array
A generic sql-based find method to query and load field information for
all records based on SQL conditions, ordering and limits including join
and grouping operations.
| Modeler | ||
[static]
Create an instance of the specified
Modeler sub-class and
load it with the record information matching given key values. | Modeler | ||
getAll(query:Object, page:int = 1, perPage:int = 0):Array
A front-end to findAll method
Returns objects of the appropriate Model type
| Modeler | ||
load(keyvals:Object):Boolean
Load this instance with record information matching specified conditions.
| Modeler | ||
reload():Boolean
Reload this previously loaded instance to obtain latest field values.
| Modeler | ||
remove():Boolean
Deletes the record represented by this object.
| Modeler | ||
save():Boolean
Save the field values in this instance to the database record.
| Modeler | ||
update(values:Object = null):Boolean
Update the database record currently loaded into the model object.
| Modeler | ||
updateAll(conditions:String, values:Object):uint
Update all records matching specified conditions with new values
| Modeler |