Interface Room


public interface Room
Deprecated.
Use the Group class instead.
A room, a zone, or another type of group that has been configured into the Hue Bridge.
  • Method Summary

    Modifier and Type Method Description
    Collection<Light> addLight​(Light newLight)
    Deprecated.
    Adds the given light into this group.
    String getId()
    Deprecated.
    Returns the technical id of the room, zone, or light group, as assigned by the Bridge.
    Optional<Light> getLightByName​(String lightName)
    Deprecated.
    Returns one light, if found by the given name.
    Collection<Light> getLights()
    Deprecated.
    Returns all the lights that have been assigned to this group.
    String getName()
    Deprecated.
    Returns the name of the room or zone, as set by the user.
    Optional<Scene> getSceneByName​(String sceneName)
    Deprecated.
    Returns one scene, if found by the given name.
    Collection<Scene> getScenes()
    Deprecated.
    Returns the scenes that belong to this group.
    GroupType getType()
    Deprecated.
    Returns the type of this group of lights, whether it is a room, a zone, or something else.
    boolean isAllOn()
    Deprecated.
    Queries the state of the group.
    boolean isAnyOn()
    Deprecated.
    Queries the state of the group of lights.
    Collection<Light> removeLight​(Light lightToBeRemoved)
    Deprecated.
    Removes the given light from this group.
    void setBrightness​(int brightness)
    Deprecated.
    Sets the brightness of the group.
    void setState​(State state)
    Deprecated.
    Sets a state for the group.
    void turnOff()
    Deprecated.
    Turns the lights off.
    void turnOn()
    Deprecated.
    Turns the lights on.
  • Method Details

    • getId

      String getId()
      Deprecated.

      Returns the technical id of the room, zone, or light group, as assigned by the Bridge. The id stays the same even if the room name is changed by the user.

      Note that the id is only unique within the context of a single bridge.

      Returns:
      Id of the room/zone/light group.
      Since:
      2.4.0
    • getName

      String getName()
      Deprecated.
      Returns the name of the room or zone, as set by the user.
      Returns:
      Name of the room or zone.
    • getLights

      Collection<Light> getLights()
      Deprecated.
      Returns all the lights that have been assigned to this group.
      Returns:
      A Collection of Light objects.
    • getLightByName

      Optional<Light> getLightByName​(String lightName)
      Deprecated.
      Returns one light, if found by the given name.
      Parameters:
      lightName - Name of a light in this group.
      Returns:
      Optional.empty() if a light is not found by this name, an Optional<Light> if it is.
    • isAnyOn

      boolean isAnyOn()
      Deprecated.
      Queries the state of the group of lights.
      Returns:
      True if any light is on in this group, false if not.
    • isAllOn

      boolean isAllOn()
      Deprecated.
      Queries the state of the group.
      Returns:
      True if all lights in this group are on, false if they are not.
    • turnOn

      void turnOn()
      Deprecated.
      Turns the lights on.
    • turnOff

      void turnOff()
      Deprecated.
      Turns the lights off.
    • setState

      void setState​(State state)
      Deprecated.
      Sets a state for the group.
      Parameters:
      state - A state to be set for this group.
    • setBrightness

      void setBrightness​(int brightness)
      Deprecated.
      Sets the brightness of the group. If the lights in the group are off, does not turn them on, nor does 0 turn them off.
      Parameters:
      brightness - A value from 0 (minimum brightness) to 254 (maximum brightness).
      Since:
      1.2.0
    • getType

      GroupType getType()
      Deprecated.
      Returns the type of this group of lights, whether it is a room, a zone, or something else.
      Returns:
      The type of this group of lights.
      Since:
      1.3.0
    • getScenes

      Collection<Scene> getScenes()
      Deprecated.
      Returns the scenes that belong to this group.
      Returns:
      The scenes of this group.
      Since:
      1.3.0
    • getSceneByName

      Optional<Scene> getSceneByName​(String sceneName)
      Deprecated.
      Returns one scene, if found by the given name.
      Parameters:
      sceneName - Name of the scene, e.g. "Tropical twilight" or "Concentrate".
      Returns:
      Optional.empty() if a scene is not found by this name, an Optional<Scene> if it is.
      Since:
      1.3.0
    • addLight

      Collection<Light> addLight​(Light newLight)
      Deprecated.
      Adds the given light into this group.
      Parameters:
      newLight - The light to be added
      Returns:
      A Collection of Lights in this room after the operation.
      Since:
      2.6.0
    • removeLight

      Collection<Light> removeLight​(Light lightToBeRemoved)
      Deprecated.
      Removes the given light from this group.
      Parameters:
      lightToBeRemoved - The light to be removed
      Returns:
      A Collection of Lights in this room after the operation
      Since:
      2.6.0