|
Doctrine 1.2.4
|
Inherits Doctrine_Search.
Public Member Functions | |
| __construct (array $options=array()) | |
| __get ($option) | |
| __isset ($option) | |
| __set ($name, $value) | |
| __unset ($name) | |
| actAs ($tpl, array $options=array()) | |
| add ($value) | |
| addChild ($generator) | |
| addListener ($listener, $name=null) | |
| analyze ($text, $encoding=null) | |
| attribute ($attr, $value) | |
| batchUpdateIndex ($limit=null, $offset=null, $encoding=null) | |
| bind ($name, $resource) | |
| bindQueryParts (array $queryParts) | |
| buildChildDefinitions () | |
| buildForeignKeys (Doctrine_Table $table) | |
| buildForeignRelation ($alias=null) | |
| buildLocalRelation ($alias=null) | |
| check ($constraint, $name=null) | |
| contains ($offset) | |
| generateClass (array $definition=array()) | |
| generateClassFromTable (Doctrine_Table $table) | |
| get ($offset) | |
| getListener () | |
| getLocator () | |
| getOption ($name) | |
| getOptions () | |
| getRelationForeignKey () | |
| getRelationLocalKey () | |
| getTable () | |
| hasColumn ($name, $type=null, $length=null, $options=array()) | |
| hasColumns (array $definitions) | |
| hasMany () | |
| hasOne () | |
| index ($name, array $definition=array()) | |
| indexDirectory ($dir) | |
| initialize (Doctrine_Table $table) | |
| initOptions () | |
| locate ($name) | |
| offsetExists ($offset) | |
| offsetGet ($offset) | |
| offsetSet ($offset, $value) | |
| offsetUnset ($offset) | |
| option ($name, $value=null) | |
| ownerHasMany ($name, $options) | |
| ownerHasOne ($name, $options) | |
| readTableData ($limit=null, $offset=null) | |
| remove ($offset) | |
| search ($string, $query=null) | |
| set ($offset, $value) | |
| setArray (array $array) | |
| setColumnOption ($columnName, $option, $value) | |
| setColumnOptions ($name, array $options) | |
| setListener ($listener) | |
| setLocator (Doctrine_Locator $locator) | |
| setOption ($name, $value) | |
| setTableDefinition () | |
| unique ($fields, $options=array(), $createUniqueIndex=true) | |
| updateIndex (array $data, $encoding=null) | |
Static Public Member Functions | |
| static | getNullObject () |
| static | initNullObject (Doctrine_Null $null) |
Protected Attributes | |
| $_initialized = false | |
| $_table | |
| Doctrine_Search_File::__construct | ( | array | $options = array() | ) |
constructor
| array | $options | an array of plugin options |
Definition at line 40 of file File.php.
|
inherited |
An alias for getOption
| string | $option |
Definition at line 64 of file Generator.php.
|
inherited |
__isset
| string | $option |
Definition at line 77 of file Generator.php.
|
inherited |
Set key and value to data
| $name | |
| $value |
Definition at line 58 of file Access.php.
|
inherited |
Remove key from data
| string | $name |
Definition at line 92 of file Access.php.
|
inherited |
Loads the given plugin.
This method loads a behavior in the record. It will add the behavior also to the record table if it. It is tipically called in
| mixed | $tpl | if an object, must be a subclass of Doctrine_Template. If a string, Doctrine will try to instantiate an object of the classes Doctrine_Template_$tpl and subsequently $tpl, using also autoloading capabilities if defined. |
| array | $options | argument to pass to the template constructor if $tpl is a class name |
| Doctrine_Record_Exception | if $tpl is neither an instance of Doctrine_Template subclass or a valid class name, that could be instantiated. |
Definition at line 349 of file Abstract.php.
|
inherited |
Add the value
| mixed | $value | The value to add |
Definition at line 199 of file Access.php.
|
inherited |
Add child record generator
| Doctrine_Record_Generator | $generator |
Definition at line 117 of file Generator.php.
|
inherited |
addListener
| Doctrine_EventListener_Interface | Doctrine_Overloadable | $listener |
Definition at line 67 of file Abstract.php.
|
inherited |
analyze a text in the encoding format
| string | $text | |
| string | $encoding |
Definition at line 123 of file Search.php.
|
inherited |
attribute sets or retrieves an option
| mixed | $attr | |
| mixed | $value |
Definition at line 182 of file Abstract.php.
|
inherited |
batchUpdateIndex
| mixed | $limit | |
| mixed | $offset |
Definition at line 221 of file Search.php.
|
inherited |
bind binds a resource to a name
| string | $name | the name of the resource to bind |
| mixed | $value | the value of the resource |
Definition at line 120 of file Injectable.php.
|
inherited |
bindQueryParts binds query parts to given component
| array | $queryParts | an array of pre-bound query parts |
Definition at line 322 of file Abstract.php.
|
inherited |
Build the child behavior definitions that are attached to this generator
Definition at line 246 of file Generator.php.
|
inherited |
Generates foreign keys for the plugin table based on the owner table. These columns are automatically added to the generated model so we can create foreign keys back to the table object that owns the plugin.
| Doctrine_Table | $table | the table object that owns the plugin |
Definition at line 279 of file Generator.php.
|
inherited |
Build the foreign relationship on the invoking table in $this->_options['table'] which points back to the model generated in this generator instance.
| string | $alias | Alias of the foreign relation |
Definition at line 358 of file Generator.php.
|
inherited |
Build the local relationship on the generated model for this generator instance which points to the invoking table in $this->_options['table']
| string | $alias | Alias of the foreign relation |
Definition at line 305 of file Generator.php.
|
inherited |
Adds a check constraint.
This method will add a CHECK constraint to the record table.
| mixed | $constraint | either a SQL constraint portion or an array of CHECK constraints. If array, all values will be added as constraint |
| string | $name | optional constraint name. Not used if $constraint is an array. |
Definition at line 388 of file Abstract.php.
|
inherited |
Check if the specified offset exists
| mixed | $offset | The offset to check |
Definition at line 188 of file Access.php.
|
inherited |
Generates the class definition for plugin class
| array | $definition | Definition array defining columns, relations and options for the model |
Definition at line 445 of file Generator.php.
|
inherited |
Generate a Doctrine_Record from a populated Doctrine_Table instance
| Doctrine_Table | $table |
Definition at line 428 of file Generator.php.
|
inherited |
Return the element with the specified offset
| mixed | $offset | The offset to return |
Definition at line 165 of file Access.php.
|
inherited |
getListener
Definition at line 79 of file Abstract.php.
|
inherited |
getLocator returns the locator associated with this object
if there are no locator locally associated then this method tries to fetch the current global locator
Definition at line 75 of file Injectable.php.
|
staticinherited |
getNullObject returns the null object associated with this object
Definition at line 145 of file Injectable.php.
|
inherited |
Returns the value of an option
| $option | the name of the option to retrieve |
Definition at line 88 of file Generator.php.
|
inherited |
Returns all options and their associated values
Definition at line 127 of file Generator.php.
|
inherited |
Get the foreign key of the generated relationship
Definition at line 394 of file Generator.php.
|
inherited |
Get the local key of the generated relationship
Definition at line 384 of file Generator.php.
|
inherited |
getTable returns the associated table object
Definition at line 56 of file Abstract.php.
|
inherited |
Sets a column definition
| string | $name | |
| string | $type | |
| integer | $length | |
| mixed | $options |
Definition at line 260 of file Abstract.php.
|
inherited |
Set multiple column definitions at once
| array | $definitions |
Definition at line 271 of file Abstract.php.
|
inherited |
Binds One-to-Many / Many-to-Many aggregate relation
| string | $componentName | the name of the related component |
| string | $options | relation options |
Definition at line 244 of file Abstract.php.
|
inherited |
Binds One-to-One aggregate relation
| string | $componentName | the name of the related component |
| string | $options | relation options |
Definition at line 229 of file Abstract.php.
|
inherited |
index defines or retrieves an index if the second parameter is set this method defines an index if not this method retrieves index named $name
| string | $name | the name of the index |
| array | $definition | the definition array |
Definition at line 107 of file Abstract.php.
| Doctrine_Search_File::indexDirectory | ( | $dir | ) |
indexes given directory
| string | $dir | the name of the directory to index |
Definition at line 70 of file File.php.
|
inherited |
Initialize the plugin. Call in Doctrine_Template setTableDefinition() in order to initiate a generator in a template
| Doctrine_Table | $table |
Definition at line 139 of file Generator.php.
|
staticinherited |
initNullObject initializes the null object
| Doctrine_Null | $null |
Definition at line 134 of file Injectable.php.
|
inherited |
Empty template method for providing the concrete plugins the ability to initialize options before the actual definition is being built
Definition at line 236 of file Generator.php.
|
inherited |
locate locates a resource by given name and returns it
if the resource cannot be found locally this method tries to use the global locator for finding the resource
| Doctrine_Locator_Exception | if the resource could not be found |
| string | $name | the name of the resource |
Definition at line 96 of file Injectable.php.
|
inherited |
Check if an offset axists
| mixed | $offset |
Definition at line 103 of file Access.php.
|
inherited |
An alias of get()
| mixed | $offset |
Definition at line 115 of file Access.php.
|
inherited |
Sets $offset to $value
| mixed | $offset | |
| mixed | $value |
Definition at line 128 of file Access.php.
|
inherited |
Unset a given offset
| mixed | $offset |
Definition at line 143 of file Access.php.
|
inherited |
option sets or retrieves an option
| mixed | $name | the name of the option |
| mixed | $value | options value |
Definition at line 206 of file Abstract.php.
|
inherited |
Add a Doctrine_Relation::MANY relationship to the generator owner table
| string | $name | |
| array | $options |
Definition at line 334 of file Generator.php.
|
inherited |
Add a Doctrine_Relation::ONE relationship to the generator owner table
| string | $name | |
| array | $options |
Definition at line 346 of file Generator.php.
|
inherited |
readTableData
| mixed | $limit | |
| mixed | $offset |
Definition at line 192 of file Search.php.
|
inherited |
Remove the element with the specified offset
| mixed | $offset | The offset to remove |
Definition at line 154 of file Access.php.
|
inherited |
Searchable keyword search
| string | $string | Keyword string to search for |
| Doctrine_Query | $query | Query object to alter. Adds where condition to limit the results using the search index |
Definition at line 94 of file Search.php.
|
inherited |
Set the offset to the value
| mixed | $offset | The offset to set |
| mixed | $value | The value to set the offset to |
Definition at line 177 of file Access.php.
|
inherited |
Set an entire aray to the data
| array | $array | An array of key => value pairs |
Definition at line 41 of file Access.php.
|
inherited |
Set an individual column option
| string | $columnName | |
| string | $option | |
| string | $value |
Definition at line 310 of file Abstract.php.
|
inherited |
Customize the array of options for a column or multiple columns. First argument can be a single field/column name or an array of them. The second argument is an array of options.
[php]
public function setTableDefinition()
{
parent::setTableDefinition();
$this->setColumnOptions('username', array(
'unique' => true
));
}
| string | $columnName | |
| array | $validators |
Definition at line 297 of file Abstract.php.
|
inherited |
setListener
| Doctrine_EventListener_Interface | Doctrine_Overloadable | $listener |
Definition at line 90 of file Abstract.php.
|
inherited |
setLocator this method can be used for setting the locator object locally
| Doctrine_Locator | the locator object |
Definition at line 60 of file Injectable.php.
|
inherited |
Sets given value to an option
| $option | the name of the option to be changed |
| $value | the value of the option |
Definition at line 104 of file Generator.php.
|
inherited |
buildDefinition
Definition at line 304 of file Search.php.
|
inherited |
Defines a n-uple of fields that must be unique for every record.
This method Will automatically add UNIQUE index definition and validate the values on save. The UNIQUE index is not created in the database until you use
| array | $fields | values are fieldnames |
| array | $options | array of options for unique validator |
| bool | $createUniqueIndex | Whether or not to create a unique index in the database |
Definition at line 128 of file Abstract.php.
|
inherited |
updateIndex updates the index
| Doctrine_Record | $record |
Definition at line 135 of file Search.php.
|
protectedinherited |
Whether or not the generator has been initialized
Definition at line 57 of file Generator.php.
|
protectedinherited |
| Doctrine_Table | $_table | reference to associated Doctrine_Table instance |
Definition at line 38 of file Abstract.php.