I am new at openhab and I am implementing a control interface for a custom irrigation system.
In openHAB 1.x the way to go was to implement a custom ItemProvider and register it as an OSGi service in parallel to the default GenericItemProvider.
As I saw the new Things and Discovery concept in eclipse smarthome project, I switched to openHAB2. There I found the ManagedItemProvider. In the description of the provider I found this:
“ManagedItemProvider is an OSGi service, that allows to add or remove items at runtime by calling ManagedItemProvider#addItem(Item) or ManagedItemProvider#removeItem(Item) .”
But now I dont know how to add items at runtime in my custom binding java code with the ManagedItemProvider.
Am I already on the right way?
Thanks in advance,