Overview  Package   Class  Tree  Index 

be.lassi.cues
Class Cue

java.lang.Object
  extended by be.lassi.base.SaveableObject
      extended by be.lassi.cues.Cue

public class Cue
extends SaveableObject

A Cue represents a state of lighting on the stage.

The lighting state is determined by the lighting levels for individual channels and levels per submaster.

Cues can be 'selected' to perform actions such as cut and copy.

A cue is 'current' when it is the cue that will be used for the next lighting action (GO). There should be only one cue that is the current cue at anyone time. It is the responsibility of the CueList class to make sure that is true.

Implementers of CueListener can listen for changes. To get notified of changes to the cue Timing, a TimingListener has to be registered with the Timing object itself.


Constructor Summary
Cue(Dirty dirty, java.lang.String number, java.lang.String page, java.lang.String prompt, java.lang.String description)
          Constructs a new cue.
Cue(java.lang.String number, java.lang.String page, java.lang.String prompt, java.lang.String description)
           
 
Method Summary
 void addListener(CueListener listener)
          Register given listener so that it will receive change notifications.
 void append(java.lang.StringBuilder b)
           
 Cue copy()
          Return a (deep) copy of this cue.
 boolean equals(java.lang.Object object)
          Return true if this cue is equal to given cue.
 java.lang.String getComment()
           
 int getCueListNumber()
           
 int getCueStepNumber()
           
 java.util.List<CueStep> getCueSteps()
           
 java.lang.String getDescription()
           
 CueDetail getDetail()
           
 int getLightCueIndex()
           
 java.lang.String getNumber()
          Get the number that identifies this cue.
 java.lang.String getPage()
          Get the play script page number that corresponds to this cue.
 java.lang.String getPrompt()
          Get the prompt text.
 int hashCode()
          
 boolean isAudioCue()
           
 boolean isCurrent()
          Return true if this cue is the 'current cue'.
 boolean isError()
           
 boolean isLightCue()
           
 boolean isSelected()
          Return true if this cue is selected.
 boolean isSingleStepCue()
           
 void removeListener(CueListener listener)
          Remove given listener so that it no longer receives change notifications.
 void setComment(java.lang.String comment)
           
 void setCueListNumber(int cueListNumber)
           
 void setCueStepNumber(int cueStepNumber)
           
 void setCurrent(boolean current)
          Mark this cue as the 'current' cue (or not).
 void setDescription(CueListener from, java.lang.String description)
           
 void setDescription(java.lang.String description)
           
 void setDescriptionTemp(java.lang.String description)
           
 void setDetail(CueDetail detail)
           
 void setLightCueIndex(int lightCueIndex)
           
 void setNumber(CueListener from, java.lang.String number)
          Set new cue number text.
 void setNumber(java.lang.String number)
          Set new cue number text.
 void setPage(java.lang.String page)
          Set new page text.
 void setPrompt(java.lang.String prompt)
          Set new prompt text.
 boolean setSelected(boolean selected)
          Mark this cue as selected.
 java.lang.String toString()
          
 
Methods inherited from class be.lassi.base.SaveableObject
doNotMarkDirty, getDirty, isDirty, markDirty, setDirty
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Cue

public Cue(Dirty dirty,
           java.lang.String number,
           java.lang.String page,
           java.lang.String prompt,
           java.lang.String description)
Constructs a new cue.

Parameters:
dirty -
number -
page -
prompt -
description -

Cue

public Cue(java.lang.String number,
           java.lang.String page,
           java.lang.String prompt,
           java.lang.String description)
Method Detail

addListener

public void addListener(CueListener listener)
Register given listener so that it will receive change notifications.

Parameters:
listener -

append

public void append(java.lang.StringBuilder b)

copy

public Cue copy()
Return a (deep) copy of this cue.

Only the values that are made persistent (written to the show file) are copied. Transient values such as 'current', 'selected' and the listeners, are not copied.

Returns:
Cue

equals

public boolean equals(java.lang.Object object)
Return true if this cue is equal to given cue.

Only the 'persistent' values are checked for equality.

Overrides:
equals in class java.lang.Object

getComment

public java.lang.String getComment()

getCueListNumber

public int getCueListNumber()

getCueStepNumber

public int getCueStepNumber()

getCueSteps

public java.util.List<CueStep> getCueSteps()

getDescription

public java.lang.String getDescription()

getDetail

public CueDetail getDetail()

getLightCueIndex

public int getLightCueIndex()

getNumber

public java.lang.String getNumber()
Get the number that identifies this cue.

Returns:
String

getPage

public java.lang.String getPage()
Get the play script page number that corresponds to this cue.

Returns:
String

getPrompt

public java.lang.String getPrompt()
Get the prompt text.

Returns:
String

hashCode

public int hashCode()

Overrides:
hashCode in class java.lang.Object

isAudioCue

public boolean isAudioCue()

isCurrent

public boolean isCurrent()
Return true if this cue is the 'current cue'.

Returns:
boolean

isError

public boolean isError()

isLightCue

public boolean isLightCue()

isSelected

public boolean isSelected()
Return true if this cue is selected.

Returns:
boolean

isSingleStepCue

public boolean isSingleStepCue()

removeListener

public void removeListener(CueListener listener)
Remove given listener so that it no longer receives change notifications.

Parameters:
listener -

setComment

public void setComment(java.lang.String comment)

setCueListNumber

public void setCueListNumber(int cueListNumber)

setCueStepNumber

public void setCueStepNumber(int cueStepNumber)

setCurrent

public void setCurrent(boolean current)
Mark this cue as the 'current' cue (or not). Notify all listeners about this change.

Parameters:
current -

setDescription

public void setDescription(CueListener from,
                           java.lang.String description)

setDescription

public void setDescription(java.lang.String description)

setDescriptionTemp

public void setDescriptionTemp(java.lang.String description)

setDetail

public void setDetail(CueDetail detail)

setLightCueIndex

public void setLightCueIndex(int lightCueIndex)

setNumber

public void setNumber(CueListener from,
                      java.lang.String number)
Set new cue number text. Notify all listeners (except given listener!) about this change.

Parameters:
from -
number -

setNumber

public void setNumber(java.lang.String number)
Set new cue number text. Notify all listeners about this change.

Parameters:
number -

setPage

public void setPage(java.lang.String page)
Set new page text.

Note that the listeners are not notified of this change. We assume that this is not required as there will be just one user interface at any one time that shows the page.

Parameters:
page -

setPrompt

public void setPrompt(java.lang.String prompt)
Set new prompt text.

Note that the listeners are not notified of this change. We assume that this is not required as there will be just one user interface at any one time that shows the prompt.

Parameters:
prompt -

setSelected

public boolean setSelected(boolean selected)
Mark this cue as selected. Notify all listeners about this change.

Parameters:
selected -

toString

public java.lang.String toString()

Overrides:
toString in class java.lang.Object

Overview  Package   Class  Tree  Index 
Lighting Assistant 1.2