Context Services: .NET Context Framework
The Context Framework is the .NET implementation of the context service requirements of the Open Wearable Computing Framework (OWCF).
It is the .NET API for collecting contextual information, performing aggregation tasks on this data and enables context aware applications to consume and filter local and remote contextual information sources. A context comprises two conceptual properties, its representation and its interpretation. The context representation comprises definitions for the data formats. The interpretation comprises (possibly a set of) programming interfaces describing the semantic meaning of the various context elements.
Context information passes through the context framework as events for which the framework implements the infrastructure allowing consumers to subscribe to context changes and to concurrently manage different interpretations of the same contextual information and implements the infrastructure needed by context providers to manage and publish their contextual information.
Exchange of context information is realized through plug-in architecture for context exchange modules with a web service based implementation, which is currently the default context implementation, and an adapter to the Java based context framework (JContextAPI).
The following picture shows the high-level components used to build the context programming framework.
The application is the client using contextual data provided by the framework. It accesses the contextual data through the context programming model, i.e., the context API. The API separates the consumer of context data from the provider of contextual data.
The context programming model allows application to access the contextual data stored in the context repository. This is done through context classes, providing a semantic interpretation of a context. A context class maps the “meaning” of some context (i.e., context interpretation) to the physical data (i.e., “context representation”). For example, a representation for temperature data might be a double while the context class applies the semantic interpretation of “Celsius” to this data. Conceptually, several context classes can be active on the same context representation data at the same time, thus, providing different interpretations of the same data.
The Context repository maintains all known context instances and allows access to this data through a query language which resembles part of the functionality of SQL but with an event driven approach. A query is used to select the “interesting” context set from the available context sources; it does not filter directly on context representation instances. The selected contexts are then associated with their default context interpretation and exposed as a context collection by the context programming API to the application.
Filling the context repository is done by context providers monitoring the environment and updating associated contextual data through the context generation framework, a layer which separates a context providers from the context repository. The context generation layer defines a context generation API that allows context providers to push changes of a context’s state to the context repository which operates on context descriptors. When a context provider detects a context change, it creates a so called context descriptor which comprises among other data the context representation of the context’s now current state.
A context provider is not limited to monitoring physical context sources but can use already computational available data as well. For example, a free/busy context provider may use a resource planning system to monitor the availability of meeting rooms or utilize the user’s mailbox to gather other peoples’ whereabouts to update the availability status.
System Requirements
The context framework is compatible with the following versions of the .NET framework
- .NET 2.0
- .NETCF 2.0 (for mobile devices)
Note that not all context providers are natively available on all platforms due to hardware constraints. However, any context can be accessed through the networking functionality provided by the framework.
Maturity Level (?)
| Component Name | Responsible Partner | Initial Maturity Level | Current Maturity Level |
| Context Services: .NET Context Framework | EMIC | 0 | 8 |

