PamView
Class LineKeyItem

java.lang.Object
  extended by PamView.LineKeyItem
All Implemented Interfaces:
PamKeyItem

public class LineKeyItem
extends java.lang.Object
implements PamKeyItem


Field Summary
private  java.awt.Color color
           
private  PamSymbol symbol
           
private  java.lang.String text
           
 
Fields inherited from interface PamView.PamKeyItem
KEY_SHORT, KEY_VERBOSE
 
Constructor Summary
LineKeyItem(java.awt.Color color, java.lang.String text)
           
 
Method Summary
 java.awt.Component getIcon(int keyType, int component)
           
 int getNumItems(int keyType)
           
 java.lang.String getText(int keyType, int component)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

color

private java.awt.Color color

text

private java.lang.String text

symbol

private PamSymbol symbol
Constructor Detail

LineKeyItem

public LineKeyItem(java.awt.Color color,
                   java.lang.String text)
Method Detail

getIcon

public java.awt.Component getIcon(int keyType,
                                  int component)
Specified by:
getIcon in interface PamKeyItem
Parameters:
keyType - type of key - verbose or short
component - component number (where there are > 1)
Returns:
a graphics component to include in the key

getNumItems

public int getNumItems(int keyType)
Specified by:
getNumItems in interface PamKeyItem
Returns:
Get's the total number of key items associated with this detection

This can be > 1 for things like the click detector which may want to show different symbols for different species.


getText

public java.lang.String getText(int keyType,
                                int component)
Specified by:
getText in interface PamKeyItem
Parameters:
keyType - type of key - verbose or short
component - component number (where there are > 1)
Returns:
text to include in the key