|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PositioningService
Interface for the Positioning Service. The service retrieves positioning data by asking all its registered plugin services.
This makes it possible for the Positioning Service to compare the data from several sources and pick the most accurate one. Currently GPS and GSM based plugins exist.
There is a many to many relationship between Positioning Services and its plugins, meening that in addition to a Position Service having more than one plugin,
the same plugin can be "plugged into" several Positioning Services.
The service generates proxy classes at runtime, so that theoretically any webservice implementing the method double[] getPosition(String username) can be used as a plugin.
The Positioning Service searches for plugins in the Discovery Service with type starting with "no.ubicollab.osgi.service.positioning."
Note that the Positioning Service can not use other Positioning Services as plugins as this could cause the system to loop forever.
The type of the Positioning Service is therefore "no.ubicollab.osgi.service.positioning" (no trailing ".") so that it will not be discovered by other Positioning Services.
no.ubicollab.osgi.service.positioning.gps.PositioningPluginService
,
no.ubicollab.osgi.service.positioning.gsm.PositioningPluginService
Method Summary | |
---|---|
double[] |
getPosition(java.lang.String username)
Gets the position of the user by asking all registered plugins. |
void |
updatePluginReferences()
Searches for new plugins and generates proxy classes. |
Method Detail |
---|
double[] getPosition(java.lang.String username)
username
- The username of the user to be located
void updatePluginReferences()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |