apollo.gui
Class ScoreCalculator

java.lang.Object
  extended by apollo.gui.ScoreCalculator
Direct Known Subclasses:
WindowScoreCalculator

public abstract class ScoreCalculator
extends java.lang.Object


Field Summary
protected  int factor
           
 
Constructor Summary
ScoreCalculator()
           
 
Method Summary
 int getFactor()
           
 javax.swing.BoundedRangeModel getModel()
          By default returns null.
 double getScoreForPosition(int position)
          Get the score for a given position
abstract  double[] getScoresForPositions(int[] positions)
           
abstract  int[] getXRange()
           
 int[] getYRange()
           
 boolean hasModel()
          Whether getModel() is non null
 void setXOrientation(int orient)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

factor

protected int factor
Constructor Detail

ScoreCalculator

public ScoreCalculator()
Method Detail

getFactor

public int getFactor()

getYRange

public int[] getYRange()

getScoreForPosition

public double getScoreForPosition(int position)
Get the score for a given position

Parameters:
position - - position to get the score for
Returns:
the score for the position

getScoresForPositions

public abstract double[] getScoresForPositions(int[] positions)

getXRange

public abstract int[] getXRange()

setXOrientation

public void setXOrientation(int orient)

hasModel

public boolean hasModel()
Whether getModel() is non null


getModel

public javax.swing.BoundedRangeModel getModel()
By default returns null. Subclass(WindowScoreCalculator) overrides if has a BoundedRangeModel associated with it