Responsible for translating data store records into entities
Fowler describes a data mapper as "A layer of Mappers that moves data between objects and a database while keeping them independent of each other and the mapper itself". http://www.martinfowler.com/eaaCatalog/dataMapper.html
Located in /Orm/Mapper/Interface.php (line 28)
Gets the first entity from the data store matching the criteria
Gets all entities from the data store matching the criteria
Gets an entity with the supplied identifier
Gets all entities from the data store
Gets the name of the domain to which this mapper belongs
Gets the class name of the entity
Gets the factory that created the mapper
Gets the fields for an entity as they appear in the backend
The array should come in the format of the describeTable method of the Zend_Db_Adapter_Abstract class.
Gets the columns that should be used to index the entity
The array should consist of index names as keys and arrays of the columns contained within as values.
Gets entities via a many-to-many table
Gets the time in seconds an entity should be cached
Gets the value of an option
Gets the options for this mapper
Gets an empty entity set for the mapper's entity type
Gets the table from which an entity comes
What the "table" means is up to the implementation. In an RDBMS, this is obvious. If the mapper is for a set of XML documents, this might represent the file name. An LDAP implementation might be a DN with an object type.
Allows for subclassing without overwriting constructor
Reloads an entity's values with fresh ones from the backend
Translates the field from the original format into the entity field name
For instance, many database users prefer to use underscores for column names, and the class should have this as a camel case word. (user_name vs. userName).
Translates the field from the entity format back into the original
For instance, many database users prefer to use underscores for column names, and the class should have this as a camel case word. (user_name vs. userName).
Documentation generated on Mon, 19 May 2008 17:07:20 -0400 by phpDocumentor 1.4.2