Class Link

java.lang.Object
  |
  +--Link

public class Link
extends java.lang.Object

A connection between two Words; displays visually as a colored line.

Author:
Noah A. Smith, Mike Jahr
See Also:
Web, Word

Field Summary
 java.awt.Color activeColor
           
 java.awt.Color passiveColor
          The color of the link when it is selected.
protected  Word sword
           
protected  Word tword
           
 
Method Summary
 void addType(int t)
          Set the type of the link.
 boolean[] getTypes()
          Get the types of the link (this refers to which alignments it is relevant to).
 Word source()
          Return the source word.
 Word target()
          Return the target word.
 void updateColors()
          Update the active and passive colors based on the Web's knowledge of the number of alignments.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sword

protected Word sword

tword

protected Word tword

activeColor

public java.awt.Color activeColor

passiveColor

public java.awt.Color passiveColor
The color of the link when it is selected.
Method Detail

source

public Word source()
Return the source word.

target

public Word target()
Return the target word.

getTypes

public boolean[] getTypes()
Get the types of the link (this refers to which alignments it is relevant to).

addType

public void addType(int t)
Set the type of the link.

updateColors

public void updateColors()
Update the active and passive colors based on the Web's knowledge of the number of alignments.