<p>
OsidContext holds contextual information that is shared by the application and the OSID implementations it uses. The osid package has some design constraints that create the need for OsidContext. They are:
These design constraints mean that there this no obvious place to put global information. The OsidContext argument of the OsidLoader.getManager method is intended to provide access to information that is global to an application and the OSID implementations that it loads. OsidContext can hold and retrieve context. The only requirement is that the information is serializable. There are OsidContext methods to get and assign context. </p>
<p> With few exceptions OSID objects are interfaces and not classes. The use of interfaces in the definition of OSID objects has some important characteristics:
These characteristics of OSIDs and the need to provide sharable contextual (global) information led to the definition of OsidContext. An application is responsible for supplying a valid OsidContext instance when it loads an OSID implementation using the OsidLoader.getManager method. This approach provides all the benefits and limitations of any system of global data. </p>
<p> OsidContext uses an unambiguous String as a key to assign the serializable context information. To retrieve the contextual information from the OsidContext the getContext method is called with the key. </p>
<p> OSID Version: 2.0 </p>
<p> Licensed under the org.osid.SidImplementationLicenseMIT. </p>
Located in /harmoni/oki2/osid/OsidContext.php (line 69)
stdClass | --OsidContext
Assign the context of the OsidContext. Context is associated with an unambiguous key, for example the context's fully qualified class name.
There is only one context asscociated with a particular key. If a context already exists for this key, that context is overwritten.
Get the context associated with this key. If the key is unknown, null is returned.
Documentation generated on Wed, 19 Sep 2007 10:25:24 -0400 by phpDocumentor 1.3.0RC3