|
Previous Page |
Solar_Sql_Model_Related_HasOne |
Next Page |
Methods
Public
__construct()- Constructor.
__destruct()- Default destructor; does nothing other than provide a safe fallback for calls to parent::__destruct().
apiVersion()- Reports the API version for this class.
dump()- Convenience method for getting a dump the whole object, or one of its properties, or an external variable.
fetchArray()- Fetches foreign data as an array.
fetchObject()- Fetches foreign data as a record or collection object.
getModel()- Returns the related (foreign) model instance.
load()- Loads this relationship object with user-defined characteristics (options), and corrects them as needed.
locale()- Looks up class-specific locale strings based on a key.
modSelectCountPages()- Modifies the SELECT from a native model countPages() call to join with the foreign model (especially on eager fetches).
modSelectEager()- When the native model is doing a select and an eager-join is requested for this relation, this method modifies the select to add the eager join.
newSelect()- Creates a new selection object for fetching records from this relation.
setNativeModel()- Sets the native (origin) model instance.
toArray()- Returns the relation characteristics as an array.
Protected
_exception()- Convenience method for returning exceptions with localized text.
_fixForeignKey()- Corrects the foreign_key value in the options; uses the native-model table name as singular.
_fixRelatedCol()- Fixes the related column names in the user-defined options in place.
_modSelect()- Modifies the base select statement for the relationship type.
_modSelectEager()- Support method for modSelectEager().
_setCols()- Sets the foreign columns to be selected based on user-defined relationship options.
_setForeignClass()- Sets the base name for the foreign class; assumes the related name is is singular and inflects it to plural.
_setForeignModel()- Sets the foreign model instance based on user-defined relationship options.
_setRelated()- A support method for _fixRelated() to handle has-one relationships.
_setSelect()- Sets additional selection clauses ('where', 'having', 'group') for related records based on user-defined relationship options.
_setType()- Sets the relationship type.
Private
None.
Local
- Overview
- Constants
- Properties
- Methods
- __construct()
- __destruct()
- _exception()
- _fixForeignKey()
- _fixRelatedCol()
- _modSelect()
- _modSelectEager()
- _setCols()
- _setForeignClass()
- _setForeignModel()
- _setRelated()
- _setSelect()
- _setType()
- apiVersion()
- dump()
- fetchArray()
- fetchObject()
- getModel()
- load()
- locale()
- modSelectCountPages()
- modSelectEager()
- newSelect()
- setNativeModel()
- toArray()