Class Hermes_Driver

Description

Hermes_Driver:: defines an API for implementing storage backends for Hermes.

$Horde: hermes/lib/Driver.php,v 1.21 2007/04/19 23:14:42 jan Exp $

Located in /lib/Driver.php (line 12)


	
			
Direct descendents
Class Description
 class Hermes_Driver_sql Hermes storage implementation for PHP's PEAR database abstraction layer.
Method Summary
 mixed deleteDeliverable (integer $deliverableID)
 mixed &factory ([string $driver = null], [array $params = null])
 mixed getDeliverableByID (integer $deliverableID)
 mixed getJobTypeByID (integer $jobTypeID)
 mixed listDeliverables ([array $criteria = array()])
 mixed listJobTypes ([array $criteria = array()])
 mixed &singleton ([string $driver = null], [array $params = null])
 mixed updateDeliverable (array $deliverable)
 mixed updateJobType (array $jobtype)
Methods
deleteDeliverable (line 144)

Delete a deliverable.

  • return: Null, or PEAR_Error on failure.
  • abstract:
mixed deleteDeliverable (integer $deliverableID)
  • integer $deliverableID: The ID of the deliverable.

Redefined in descendants as:
factory (line 160)

Attempts to return a concrete Hermes_Driver instance based on $driver.

  • return: The newly created concrete Hermes_Driver instance, or false on error.
mixed &factory ([string $driver = null], [array $params = null])
  • string $driver: The type of concrete Hermes_Driver subclass to return.
  • array $params: A hash containing any additional configuration or connection parameters a subclass might need.
getDeliverableByID (line 77)

Retrieve a deliverable by ID.

  • return: Hash of deliverable's properties, or PEAR_Error on failure.
mixed getDeliverableByID (integer $deliverableID)
  • integer $deliverableID: The ID of the deliverable to retrieve.
getJobTypeByID (line 21)

Retrieve a specific job type record.

  • return: Hash of job type properties, or PEAR_Error on failure.
mixed getJobTypeByID (integer $jobTypeID)
  • integer $jobTypeID: The ID of the job type.
listDeliverables (line 131)

Retrieve list of deliverables.

  • return: Associative array of job types, or PEAR_Error on failure.
  • abstract:
mixed listDeliverables ([array $criteria = array()])
  • array $criteria: A hash of search criteria: 'id' => If present, only deliverable with specified ID is searched for. 'client_id' => If present, list is filtered by client ID.

Redefined in descendants as:
listJobTypes (line 64)

Retrieve list of job types.

  • return: Associative array of job types, or PEAR_Error on failure.
  • abstract:
mixed listJobTypes ([array $criteria = array()])
  • array $criteria:

    Hash of filter criteria:

    'enabled' => If present, only retrieve enabled or disabled job types.


Redefined in descendants as:
singleton (line 202)

Attempts to return a reference to a concrete Hermes_Driver instance based on $driver.

It will only create a new instance if no Hermes_Driver instance with the same parameters currently exists.

This should be used if multiple storage sources are required.

This method must be invoked as: $var = &Hermes_Driver::singleton()

  • return: The created concrete Hermes_Driver instance, or false on error.
mixed &singleton ([string $driver = null], [array $params = null])
  • string $driver: The type of concrete Hermes_Driver subclass to return.
  • array $params: A hash containing any additional configuration or connection parameters a subclass might need.
updateDeliverable (line 113)

Add or update a deliverable.

  • return: Integer ID of new or saved deliverable, or PEAR_Error on failure.
  • abstract:
mixed updateDeliverable (array $deliverable)
  • array $deliverable: A hash of deliverable properties: 'id' => The ID of the deliverable, if updating. If not present, a new ID is allocated. 'name' => The deliverable's display name. 'client_id' => The assigned client ID. 'parent' => ID of the deliverables parent deliverable (if a child). 'estimate' => Estimated number of hours for completion of the deliverable. 'active' => Whether this deliverable is active. 'description' => Text description (notes) for this deliverable.

Redefined in descendants as:
updateJobType (line 47)

Add or update a job type record.

  • return: The job's ID, or PEAR_Error on failure.
  • abstract:
mixed updateJobType (array $jobtype)
  • array $jobtype: A hash of job type properties: 'id' => The ID of the job, if updating. If not present, a new job type is created. 'name' => The job type's name. 'enabled' => Whether the job type is enabled for new time entry.

Redefined in descendants as:

Documentation generated on Sun, 30 Jan 2011 05:25:48 +0000 by phpDocumentor 1.4.3