SourceForge.net LogoPHPGallue
[ class tree: libgallue ] [ index: libgallue ] [ all elements ]

Class: GALGallueTable

Source Location: /libgallue/GALGallueTable.inc.php

Class Overview

GALTable
   |
   --GALGallueTable

Class with some common methods.


Author(s):

Variables

Methods


Child classes:

GALUsers
Manage users and handle database communication.
GALNodes
Manage nodes and handle database communication.
GALFilms
Manage films and handle database communication.
GALHelps
GALComments
Manage groups and handle database communication.
GALImages
Manage images and handle database communication.
GALSeriesT
GALGroups
Manage groups and handle database communication.
GALInstances
Manage images and handle database communication.
GALLogins
GALJobs
Manage jobs and handle database communication.
GALCategories
Manage categories and handle database communication.
GALTokens

Inherited Variables

Inherited Methods

Class: GALTable

GALTable::__construct()
Initializes this table.
GALTable::buildResult()
Implements the GALResultFactory interface.
GALTable::compareExpression()
Factory for GALExpressionCompare objects.
GALTable::containsKeyFields()
Checks if the specified fields contains a field that belongs to the primary key.
GALTable::count()
Count rows that match the given GALExpression.
GALTable::countFields()
Returns the number of fields contained in a result.
GALTable::delete()
Deletes the row identified by $key from the database.
GALTable::extendedCount()
Template for complex count queries.
GALTable::extendedLoad()
Template for complex queries.
GALTable::fullKey()
Checks if the specified fields in $keys are the full primary key.
GALTable::getFields()
Returns all fields contained in this result.
GALTable::getFlags()
Gets the flags of the given field.
GALTable::getIfRegistered()
Return the row with the submitted primary key values, if it has been registered before.
GALTable::getLength()
Gets the length of the given field.
GALTable::getName()
Returns this table's name.
GALTable::getParent()
Returns a reference to this table.
GALTable::getPrimaryKey()
Returns the primary key of this table.
GALTable::getResultFactory()
Returns the factory to construct results.
GALTable::getRowFactory()
Returns the factory to construct rows.
GALTable::getTable()
Gets the name of the table the given field is contained in.
GALTable::getType()
Gets the type of the given field.
GALTable::insert()
Inserts a row into this table.
GALTable::insertMultiple()
Inserts multiple rows into the database.
GALTable::isField()
Checks if the given field is contained in a result.
GALTable::load()
Load rows that match the given GALExpression.
GALTable::rawCount()
Counts rows from this table.
GALTable::rawLoad()
Loads rows from this table.
GALTable::register()
Registers the specified row or returns an already registered row.
GALTable::registered()
Checks if the specified row is already registered.
GALTable::row()
Fetches a row matching the given key from the database.
GALTable::setRegistered()
Set the entry in $rows specified by &$keys to the specified value.
GALTable::stripKeys()
Removes all fields from the submitted data which belong to the primary key.
GALTable::unregister()
Removes a registered row.
GALTable::updateRow()
Sets the fields of the specified row to the specified values.
GALTable::validFields()
Checks if all the field names submitted in $fields are valid.
GALTable::__destruct()
Destructs all rows stored in $rows.

Class Details

[line 38]
Class with some common methods.

As most tables have certain common fields like permission, ownerID, title, comment and createDate, it is possible to implement some methods in this central place.




Tags:

abstract:  


[ Top ]


Class Variables

$glb =

[line 42]



Tags:

access:  protected

Type:   GALGallery


[ Top ]



Class Methods


constructor __construct [line 50]

GALGallueTable __construct( GALGallery $glb, string $tableName)

Initializes $glb object variable.

Initialize the $glb object variable and call the parent constructor.




Overridden in child classes as:

GALUsers::__construct()
Initialize using GALGallery object.
GALNodes::__construct()
Initialize using GALGallery object.
GALFilms::__construct()
Initialize using GALGallery object.
GALHelps::__construct()
GALComments::__construct()
Initializes using a GALGallery object.
GALImages::__construct()
Initialize using GALGallery object.
GALSeriesT::__construct()
GALGroups::__construct()
Initializes using a GALGallery object.
GALInstances::__construct()
Initialize using GALGallery object.
GALLogins::__construct()
GALJobs::__construct()
Initialize using GALGallery object.
GALCategories::__construct()
Initialize using GALGallery object.
GALTokens::__construct()

Overrides GALTable::__construct() (Initializes this table.)

Parameters:

GALGallery   $glb   Link to this table's GALGallery object.
string   $tableName   The "real" table name of this table.

[ Top ]

method search [line 113]

GALExpression search( string $term)

SQL expression that searches for items containing $term.

At the moment the search is a comparison via "LIKE". This is inefficient if you search a lot of text. Infortunately MySQL supports full text indices only for MyISAM tables. Maybe I find a way to improve this.




Overridden in child classes as:

GALUsers::search()
Search for an user.
GALNodes::search()
Searching nodes is nor supported.
GALInstances::search()
Searching instances is nor supported.
GALLogins::search()
Searching logins is nor supported.
GALJobs::search()
Searching jobs is nor supported.
GALTokens::search()
Searching tokens is nor supported.

Parameters:

string   $term  

[ Top ]

method visible [line 61]

GALExpression visible( )

SQL expression that is TRUE only for items visible to the user currently logged in.

This method doesn't use the advanced SQL comparison class GALExpressionCompare, because it was derivated from existing code ;-).




Tags:

return:  A SQL logical expression that evaluates to TRUE for visible items.


Overridden in child classes as:

GALUsers::visible()
SQL expression that is TRUE only for users visible to the user currently logged in.
GALFilms::visible()
SQL expression that is TRUE only for items visible to the user currently logged in.
GALHelps::visible()
GALImages::visible()
SQL expression that is TRUE only for images visible to the user currently logged in.
GALSeriesT::visible()
SQL expression that is TRUE only for items visible to the user currently logged in.
GALGroups::visible()
SQL expression that is TRUE only for items visible to the user currently logged in.
GALCategories::visible()
SQL expression that is TRUE only for items visible to the user currently logged in.

[ Top ]

method writeable [line 88]

GALExpression writeable( )

SQL expression that is TRUE only for items writeable by the user currently logged in.

This method doesn't use the advanced SQL comparison class GALExpressionCompare, because it was derivated from existing code ;-).




Tags:

return:  A SQL logical expression that evaluates to TRUE for writeable items.


Overridden in child classes as:

GALUsers::writeable()
SQL expression that is TRUE only for users writeable by the user currently logged in.
GALFilms::writeable()
SQL expression that is TRUE only for items writeable by the user currently logged in.
GALHelps::writeable()
GALImages::writeable()
SQL expression that is TRUE only for images writeable by the user currently logged in.
GALSeriesT::writeable()
SQL expression that is TRUE only for items writeable by the user currently logged in.
GALGroups::writeable()
SQL expression that is TRUE only for items writeable by the user currently logged in.
GALCategories::writeable()
SQL expression that is TRUE only for items writeable by the user currently logged in.

[ Top ]


Documentation generated on Wed, 16 Aug 2006 15:35:49 +0200 by phpDocumentor 1.3.0RC6