Class HarmoniIdManager

Description

IdManager creates and gets Ids. Ids are used in many different contexts throughout the OSIDs. As with other Managers, use the OsidLoader to load an implementation of this interface.

All implementations of OsidManager (manager) provide methods for accessing and manipulating the various objects defined in the OSID package. A manager defines an implementation of an OSID. All other OSID objects come either directly or indirectly from the manager. New instances of the OSID objects are created either directly or indirectly by the manager. Because the OSID objects are defined using interfaces, create methods must be used instead of the new operator to create instances of the OSID objects. Create methods are used both to instantiate and persist OSID objects. Using the OsidManager class to define an OSID's implementation allows the application to change OSID implementations by changing the OsidManager package name used to load an implementation. Applications developed using managers permit OSID implementation substitution without changing the application source code. As with all managers, use the OsidLoader to load an implementation of this interface.

Unlike most Managers, IdManager does not have methods to return Type information.

OSID Version: 2.0

  • version: $Id: HarmoniIdManager.class.php,v 1.26 2007/09/13 16:04:20 adamfranco Exp $
  • license: GNU General Public License (GPL)
  • copyright: Copyright © 2005, Middlebury College

Located in /harmoni/core/oki2/id/HarmoniIdManager.class.php (line 48)

OsidManager
   |
   --IdManager
      |
      --HarmoniIdManager
Variable Summary
integer $_dbIndex
array $_ids
Method Summary
HarmoniIdManager HarmoniIdManager (integer 0)
void assignConfiguration (object Properties $configuration)
void assignOsidContext (mixed $context, object OsidContext $context )
object Id createId ()
object Id getId (mixed $idString, string $idString )
object OsidContext getOsidContext ()
Variables
integer $_dbIndex (line 57)

The database connection as returned by the DBHandler.

  • var: _dbIndex
  • access: private
array $_ids (line 65)

An array of all cached Id objects.

  • var: _ids
  • access: private
Methods
Constructor HarmoniIdManager (line 72)

Constructor. Set up any database connections needed.

HarmoniIdManager HarmoniIdManager (integer 0)
  • integer 0: dbIndex The database connection as returned by the DBHandler.
assignConfiguration (line 98)

Assign the configuration of this Manager. Valid configuration options are as

follows: database_index integer database_name string

  • access: public
  • throws: object OsidException An exception with one of the following messages defined in org.osid.OsidException: OPERATION_FAILED, PERMISSION_DENIED, CONFIGURATION_ERROR, UNIMPLEMENTED, NULL_ARGUMENT
void assignConfiguration (object Properties $configuration)
  • object Properties $configuration: (original type: java.util.Properties)

Redefinition of:
OsidManager::assignConfiguration()
Assign the configuration of this OsidManager.
assignOsidContext (line 140)

Assign the context of this OsidManager.

  • access: public
  • throws: object OsidException An exception with one of the following messages defined in org.osid.OsidException: NULL_ARGUMENT
void assignOsidContext (mixed $context, object OsidContext $context )
  • object OsidContext $context

Redefinition of:
OsidManager::assignOsidContext()
Assign the context of this OsidManager.
createId (line 160)

Create a new unique identifier.

  • access: public
  • throws: object IdException An exception with one of the following messages defined in org.osid.id.IdException: OPERATION_FAILED, PERMISSION_DENIED, CONFIGURATION_ERROR, UNIMPLEMENTED
object Id createId ()

Redefinition of:
IdManager::createId()
Create a new unique identifier.
getId (line 216)

Get the unique Id with this String representation or create a new unique Id with this representation.

  • access: public
  • throws: object IdException An exception with one of the following messages defined in org.osid.id.IdException: OPERATION_FAILED, PERMISSION_DENIED, CONFIGURATION_ERROR, UNIMPLEMENTED, NULL_ARGUMENT
object Id getId (mixed $idString, string $idString )
  • string $idString

Redefinition of:
IdManager::getId()
Get the unique Id with this String representation or create a new unique Id with this representation.
getOsidContext (line 125)

Return context of this OsidManager.

  • access: public
  • throws: object OsidException
object OsidContext getOsidContext ()

Redefinition of:
OsidManager::getOsidContext()
Return context of this OsidManager.

Inherited Methods

Inherited From IdManager

IdManager::createId()
IdManager::getId()

Inherited From OsidManager

OsidManager::assignConfiguration()
OsidManager::assignOsidContext()
OsidManager::getOsidContext()
OsidManager::osidVersion_2_0()

Documentation generated on Wed, 19 Sep 2007 10:24:04 -0400 by phpDocumentor 1.3.0RC3