KWeb  6.4
KWebSource_Sql_Record Class Reference

Data is stored as a single record per row. More...

Inheritance diagram for KWebSource_Sql_Record:
KWebSource_Sql KWebSource

Public Member Functions

 commitUpdates (KWebObject_Attributable $object, KWebAttribute_Table_Class $attributes)
 Commits remaining updates to the data source.
 fetchDataForUids ($uids, $genre, KWebAttribute_Table_Class $attributes, $languages=false, $mainLanguage=false)
 Fetches data for specified object UIDs and languages.

Data Fields

 $keyMainLang
 Column with the main language.
 $useRequestedId = false
 Will try to use requested id in the specified data attribute if original id is temporary (or null) Requested ids are not enforced - if it is already occupied, another one will be generated string - data attribute id TRUE - DATA_REQUESTED_ID FALSE - off.
 $useGeneratedId = false
 Will try to generate new id callable - Callback function to use TRUE - database auto increment FALSE - off.

Detailed Description

Data is stored as a single record per row.


Member Function Documentation

KWebSource_Sql_Record::commitUpdates ( KWebObject_Attributable object,
KWebAttribute_Table_Class attributes 
)

Commits remaining updates to the data source.

Returns:
boolean TRUE if any changes where found

Reimplemented from KWebSource.

KWebSource_Sql_Record::fetchDataForUids ( uids,
genre,
KWebAttribute_Table_Class attributes,
languages = false,
mainLanguage = false 
)

Fetches data for specified object UIDs and languages.

Parameters:
$objectsArray of object UIDs, or IDs
$genreDefault genre for UIDs
$languagesArray of languages to fetch or false for every language
$mainLanguageMain language - results will be sorted, with the main language as the first one
Returns:
array results as [$genre][$objectId][$lang] => array(data)

Reimplemented from KWebSource.


Field Documentation

KWebSource_Sql_Record::$keyMainLang

Column with the main language.

KWebSource_Sql_Record::$useGeneratedId = false

Will try to generate new id callable - Callback function to use TRUE - database auto increment FALSE - off.

KWebSource_Sql_Record::$useRequestedId = false

Will try to use requested id in the specified data attribute if original id is temporary (or null) Requested ids are not enforced - if it is already occupied, another one will be generated string - data attribute id TRUE - DATA_REQUESTED_ID FALSE - off.


The documentation for this class was generated from the following file: