Turba_DriverThe Turba_Driver:: class provides a common abstracted interface to the various directory search drivers. It includes functions for searching, adding, removing, and modifying directory entries.
$Horde: turba/lib/Driver.php,v 1.57.2.101 2011-01-17 13:59:05 jan Exp $
Located in /lib/Driver.php (line 13)
| Class | Description |
|---|---|
Turba_Driver_favourites
|
Read-only Turba directory driver implementation for favourite recipients. Relies on the contacts/favouriteRecipients API method. |
Turba_Driver_group
|
Read-only Turba_Driver implementation for creating a Horde_Group based address book. |
Turba_Driver_imsp
|
Turba directory driver implementation for an IMSP server. |
Turba_Driver_kolab
|
Horde Turba driver for the Kolab IMAP Server. |
Turba_Driver_ldap
|
Turba directory driver implementation for PHP's LDAP extension. |
Turba_Driver_null
|
Null Turba directory driver. |
Turba_Driver_prefs
|
Turba directory driver implementation for Horde Preferences - very simple, lightweight container. |
Turba_Driver_share
|
The Turba_Driver:: class provides a common abstracted interface to the various directory search drivers. It includes functions for searching, adding, removing, and modifying directory entries. |
Turba_Driver_vbook
|
Turba directory driver implementation for virtual address books. |
Turba_Driver_sql
|
Turba directory driver implementation for PHP's PEAR database abstraction layer. |
array
makeSearch
( $criteria, string $search_type, array $strict, [boolean $match_begin = false], array $hash)
The
&search
(array $search_criteria, [string $sort_order = null], [string $search_type = 'AND'], [array $return_fields = array()], [array $custom_strict = array()], [boolean $match_begin = false])
Horde_iCalendar_vcard
tovCard
(Turba_Object $object, [string $version = '2.1'], [array $fields = null], [boolean $skipEmpty = false])
string
$alternativeName
= null (line 80)
The name of a field to use as an alternative to the name field if that one is empty.
array
$approximate
= array() (line 65)
Array of fields to search "approximately" (@see config/sources.php.dist).
array
$fields
= array() (line 50)
List of all fields that can be accessed in the backend (excludes composite attributes, etc.).
string
$listNameField
= null (line 72)
The name of a field to store contact list names in if not the default.
array
$map
= array() (line 35)
Hash describing the mapping between Turba attributes and driver-specific fields.
string
$name
(line 20)
The internal name of this source.
array
$strict
= array() (line 57)
Array of fields that must match exactly.
array
$tabs
= array() (line 42)
Hash with all tabs and their fields.
string
$title
(line 27)
The symbolic title of this source.
array
$_capabilities
= array() (line 94)
What can this backend do?
string
$_contact_owner
= '' (line 108)
Hold the value for the owner of this address book.
integer
$_count
= null (line 101)
Number of contacts in this source.
array
$_params
= array() (line 87)
Hash holding the driver's additional parameters.
Constructor Turba_Driver (line 116)
Constructs a new Turba_Driver object.
add (line 766)
Adds a new entry to the contact source.
canAdd (line 802)
Returns ability of the backend to add new contacts.
checkDefaultShare (line 2593)
Check if the passed in share is the default share for this source.
count (line 902)
Returns the number of contacts of the current user in this address book.
createShare (line 2373)
Creates a new Horde_Share for this source type.
delete (line 817)
Deletes the specified entry from the contact source.
deleteAll (line 861)
Deletes all contacts from an address book.
generateUID (line 945)
Generates a universal/unique identifier for a contact. This is NOT something that we expect to be able to parse into an addressbook and a contactId.
getBlobs (line 148)
Returns the attributes that are blob types.
getContactOwner (line 2352)
Return the owner to use when searching or creating contacts in this address book.
getCountry (line 1873)
Returns the (localized) country name.
getCriteria (line 920)
Returns the criteria available for this source except '__key'.
getFields (line 933)
Returns all non-composite fields for this source. Useful for importing and exporting data, etc.
getName (line 2341)
Return the name of this address book.
(This is the key into the cfgSources array)
getObject (line 741)
Retrieves one object from the source.
getObjects (line 694)
Retrieves a set of objects from the source.
getParams (line 126)
Returns the current driver's additional parameters.
hasCapability (line 138)
Checks if this backend has a certain capability.
hasPermission (line 2322)
Checks if the current user has the requested permissions on this address book.
listTimeObjects (line 578)
Returns a list of birthday or anniversary hashes from this source for a certain period.
makeSearch (line 271)
Takes a hash of Turba key => search value and return a (possibly nested) array, using backend attribute names, that can be turned into a search by the driver. The translation is based on the contents of $this->map, and includes nested OR searches for composite fields.
removeUserData (line 2579)
Remove all entries owned by the specified user.
save (line 877)
Modifies an existing entry in the contact source.
search (line 471)
Searches the source based on the provided criteria.
singleton (line 2478)
Attempts to return a reference to a concrete Turba_Driver instance based on the $config array. It will only create a new instance if no Turba_Driver instance with the same parameters currently exists.
This method must be invoked as: $driver = &Turba_Driver::singleton()
toDriver (line 416)
Translates a single Turba attribute to the driver-specific counterpart. The translation is based on the contents of $this->map. This ignores composite fields.
toDriverKeys (line 172)
Translates the keys of the first hash from the generalized Turba attributes to the driver-specific fields. The translation is based on the contents of $this->map.
toHash (line 1894)
Function to convert a Horde_iCalendar_vcard object into a Turba Object Hash with Turba attributes suitable as a parameter for add().
toTurbaKeys (line 438)
Translates a hash from being keyed on driver-specific fields to being keyed on the generalized Turba attributes. The translation is based on the contents of $this->map.
tovCard (line 963)
Exports a given Turba_Object as an iCalendar vCard.
_add (line 2549)
Adds the specified contact to the SQL database.
_canAdd (line 807)
_delete (line 2557)
Deletes the specified contact from the SQL database.
_getContactOwner (line 2360)
_getTimeObjectTurbaList (line 663)
Default implementation for obtaining a Turba_List to get TimeObjects out of.
_getTimeObjectTurbaListFallback (line 679)
Default implementation for obtaining a Turba_List to get TimeObjects out of.
_init (line 2511)
Initialize the driver.
_makeKey (line 2391)
Creates an object key for a new object.
_read (line 2541)
Reads the given data from the address book and returns the results.
_save (line 2567)
Saves the specified object in the SQL database.
_search (line 2526)
Searches the address book with the given criteria and returns a filtered list of results. If the criteria parameter is an empty array, all records will be returned.
_toTurbaObjects (line 537)
Takes an array of object hashes and returns a Turba_List containing the correct Turba_Objects
Documentation generated on Sun, 30 Jan 2011 05:39:22 +0000 by phpDocumentor 1.4.3