Class CommandOption

java.lang.Object
org.openhab.core.types.CommandOption

@NonNullByDefault public class CommandOption extends Object
Represents a command option for "write only" command channels. CommandOptions will be rendered as push-buttons in the UI and will not represent a state.
Author:
Henning Treu - Initial contribution
  • Constructor Details

    • CommandOption

      public CommandOption(String command, @Nullable String label)
      Creates a CommandOption object.
      Parameters:
      command - the command of the item
      label - label
  • Method Details

    • getCommand

      public String getCommand()
      Returns the command.
      Returns:
      command
    • getLabel

      public @Nullable String getLabel()
      Returns the label.
      Returns:
      label
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(@Nullable Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object