gcspy.vis
Class MarkerRange

java.lang.Object
  extended by gcspy.vis.MarkerRange

 class MarkerRange
extends java.lang.Object

A marker range

Author:
Tony Printezis

Constructor Summary
MarkerRange(int m1, int m2)
          Create a new range
 
Method Summary
 void copyFrom(MarkerRange range)
          Copy a marker range
 int getFrom()
          Get the start of the range
 int getTo()
          Get the end of the range
 boolean isNewlyAdded()
          The range has been newly added
 void set(int m1, int m2)
          Set a new range
 void setFrom(int from)
          Set the start of the range
 void setTo(int to)
          Set the end of the range
 void unsetNewlyAdded()
          The range has not been newly added
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MarkerRange

public MarkerRange(int m1,
                   int m2)
Create a new range

Parameters:
m1 - The index of one end of the range
m2 - The index of the other end of the range
Method Detail

getFrom

public int getFrom()
Get the start of the range

Returns:
the index of the start of the range

getTo

public int getTo()
Get the end of the range

Returns:
the index of the end of the range

unsetNewlyAdded

public void unsetNewlyAdded()
The range has not been newly added


isNewlyAdded

public boolean isNewlyAdded()
The range has been newly added


set

public void set(int m1,
                int m2)
Set a new range

Parameters:
m1 - The index of one end of the range
m2 - The index of the other end of the range

setTo

public void setTo(int to)
Set the end of the range


setFrom

public void setFrom(int from)
Set the start of the range


copyFrom

public void copyFrom(MarkerRange range)
Copy a marker range

Parameters:
range - The source range