All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class edu.cmu.owl.bo.control.server.LuxmateLightControllerImpl

edu.cmu.owl.bo.control.server.ControllableObject
   |
   +----edu.cmu.owl.bo.control.server.LuxmateLightControllerImpl

public class LuxmateLightControllerImpl
extends ControllableObject
implements LightController
This class is the Luxmate Implementation of a Light Fixture. This class needs to implement a listener for luxmate wrapper in order to notify for events

Version:
1.0

Constructor Index

 o LuxmateLightControllerImpl(LuxmateLightingFixture)
This constructor instantiates an object of this class.

Method Index

 o addListener(LightEventListener)
This method adds a listener to the events of this light
 o brighten(int)
This method brightens the light by reln
 o dim(int)
This method dims the light by reln
 o getCurrentLevel()
This method returns the current level of this light
 o isFaulty()
This method returns whether this light is faulty or not
 o isOn()
This method returns whether the light is on
 o removeListener(LightEventListener)
This method removes a listener of the events of this light
 o setCurrentLevel(float)
This method sets the level of the light
 o turnOff()
This method turns this light off.
 o turnOn()
This method turns this light on.

Constructors

 o LuxmateLightControllerImpl
 public LuxmateLightControllerImpl(LuxmateLightingFixture peer) throws RemoteException
This constructor instantiates an object of this class.

Parameters:
peer - the OwlObject peer for this light
Throws: RemoteException
if the remote communication fails

Methods

 o turnOn
 public void turnOn() throws RemoteException
This method turns this light on.

Throws: RemoteException
if the remote communication fails
 o turnOff
 public void turnOff() throws RemoteException
This method turns this light off.

Throws: RemoteException
if the remote communication fails
 o dim
 public void dim(int reln) throws RemoteException
This method dims the light by reln

Parameters:
reln - the value by which to dim the lights
Throws: RemoteException
if the remote communication fails
 o brighten
 public void brighten(int reln) throws RemoteException
This method brightens the light by reln

Parameters:
reln - the value by which to dim the lights
Throws: RemoteException
if the remote communication fails
 o isOn
 public boolean isOn() throws RemoteException
This method returns whether the light is on

Returns:
whether the light is on or not
Throws: RemoteException
if the remote communication fails
 o getCurrentLevel
 public float getCurrentLevel() throws RemoteException
This method returns the current level of this light

Returns:
the current level of this light
Throws: RemoteException
if the remote communication fails
 o isFaulty
 public boolean isFaulty() throws RemoteException
This method returns whether this light is faulty or not

Returns:
whether this light is faulty or not
Throws: RemoteException
if the remote communication fails
 o setCurrentLevel
 public void setCurrentLevel(float level) throws RemoteException
This method sets the level of the light

Parameters:
level - the desired level to which to set the light
Throws: RemoteException
if the remote communication fails
 o addListener
 public synchronized void addListener(LightEventListener listener) throws RemoteException
This method adds a listener to the events of this light

Parameters:
listener - the client implementation of the listener
Throws: RemoteException
if the remote communication fails
 o removeListener
 public synchronized void removeListener(LightEventListener listener) throws RemoteException
This method removes a listener of the events of this light

Parameters:
listener - the client implementation of the listener to remove
Throws: RemoteException
if the remote communication fails

All Packages  Class Hierarchy  This Package  Previous  Next  Index