Ciao Walter,
E' corretto: JEMMA espone un certo numero di API via JSON-RPC (ad
esempio
GreenAtHomeApplianceService)
che sono "chiamate" dalle GUI web-based.
Abbiamo anche in roadmap un'attività di
refactoring e
documentazione delle API principali che speriamo di inserire
in una della prossime milestone (0.2 o 0.3) in base alla
disponibilità dei collaboratori al progetto.
Alcune informazioni più dettagliate di seguito (mi scuso per
l'inglese ma è un cut & paste di una mail di un collaboratore
che non parla italiano)
A JSON-RPC interface is exposed over
HTTP by [jemma.osgi.ah.web.energyathome.demo] bundle.
In particular, at the EnergyAtHome class, it registers into a
jabsorb JSONBridge an instance of ServiceRegistryProxy.
Hence, The JSONBridge will export all the instance methods
(bind, close, find and unbind) under the key "OSGi".
Finally, in the Web GUI there is also a javascript library
json-rpc (jsonrpc.js) which is used as josn-rpc client.
Similarly, the class StaticJSONServiceTracker(from the same
bundle) exposes over json-rpc all the service instances of
GreenAtHomeApplianceService
from [jemma.osgi.ah.greenathome] bundle with Property
(bind.protocol=json-rpc) under the key value of property("
service.id").
However, at execution, property("
service.id")
value will be an integer number like (100, 97, ...).
PS. Se puoi farci qualche esempio di "chiamata" che ti interessa
con i suoi parametri possiamo provare a indirizzarti verso la
funzione giusta (se esiste già).
A presto,
R.
---
Riccardo Tomasi
Head of Research Unit: Internet of Things Service Management
(IoT-SM)
Pervasive Technologies (
PerT)
Area
Istituto Superiore Mario Boella (
ISMB)
skype: riccardo1981
[
My calendar]
[
Linkedin]
[
Disclaimer]