Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse SmartHome » Add Options to String Channel Dynamically
Add Options to String Channel Dynamically [message #1759109] Thu, 06 April 2017 14:13 Go to next message
Zocker 1996 is currently offline Zocker 1996Friend
Messages: 2
Registered: April 2017
Junior Member
I got a channel with a string type and some options.
I want to add options to the list as the config of the thing updates.
Do I have to create a new ChannelType each time? If so how do I do that?
Where do I need to register the new ChannelType and unregister the old one?
Re: Add Options to String Channel Dynamically [message #1759251 is a reply to message #1759109] Sat, 08 April 2017 12:06 Go to previous message
Kai Kreuzer is currently offline Kai KreuzerFriend
Messages: 648
Registered: December 2011
Senior Member
Yes, you would ideally require different channel types (assuming that the changed options also semantically mean a different functionality).
Assuming you are dealing with a configuration update in "handleConfigurationUpdate", you can call "editThing" and use the returned ThingBuilder to change the structure (i.e. the channels) of your Thing.
See here for details: https://www.eclipse.org/smarthome/documentation/development/bindings/thing-handler.html#updating-the-thing-structure
Previous Topic:ESH Scheduling UI
Next Topic:How to use Trigger-Channels?
Goto Forum:
  


Current Time: Tue Jun 19 11:02:30 GMT 2018

Powered by FUDForum. Page generated in 0.01466 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top