gate.gui.docview
Class AnnotationStackView

java.lang.Object
  extended by gate.util.AbstractFeatureBearer
      extended by gate.creole.AbstractResource
          extended by gate.gui.docview.AbstractDocumentView
              extended by gate.gui.docview.AnnotationStackView
All Implemented Interfaces:
AnnotationListener, ActionsPublisher, DocumentView, Resource, FeatureBearer, NameBearer, VisualResource, Serializable, EventListener

public class AnnotationStackView
extends AbstractDocumentView
implements AnnotationListener

Show a stack view of highlighted annotations in the document centred on the document caret. When double clicked, an annotation is copied to another set in order to create a gold standard set from several annoatator sets. You can choose to display features with annotations by clicking the first column rectangles.

See Also:
Serialized Form

Nested Class Summary
(package private)  class AnnotationStackView.AnnotationMouseListener
           
protected  class AnnotationStackView.HeaderMouseListener
           
(package private)  class AnnotationStackView.NextAnnotationAction
           
(package private)  class AnnotationStackView.PreviousAnnotationAction
           
 
Field Summary
(package private)  AnnotationListView annotationListView
           
(package private)  AnnotationSetsView annotationSetsView
           
(package private)  Document document
           
(package private)  JPanel mainPanel
           
(package private)  AnnotationStackView.NextAnnotationAction nextAnnotationAction
           
(package private)  AnnotationStackView.PreviousAnnotationAction previousAnnotationAction
           
(package private)  JScrollPane scroller
           
(package private)  AnnotationStack stackPanel
           
(package private)  JLabel targetSetLabel
           
(package private)  String targetSetName
           
(package private)  TextualDocumentView textView
           
(package private)  Map<String,String> typesFeatures
          optionally map a type to a feature when the feature value must be displayed in the rectangle annotation
 
Fields inherited from class gate.gui.docview.AbstractDocumentView
active, guiInitialised, handle, owner
 
Fields inherited from class gate.creole.AbstractResource
name
 
Fields inherited from class gate.util.AbstractFeatureBearer
features
 
Fields inherited from interface gate.gui.docview.DocumentView
CENTRAL, HORIZONTAL, VERTICAL
 
Constructor Summary
AnnotationStackView()
           
 
Method Summary
 void annotationUpdated(AnnotationEvent e)
          Called when an Annotation has been updated
(package private)  boolean askTargetSet()
           
 void cleanup()
          releases the memory allocated to this resource
 Component getGUI()
          Returns the actual UI component this view represents.
 int getType()
          Returns the type of this view.
protected  void initGUI()
          Implementers should override this method and use it for populating the GUI.
protected  void initListeners()
           
protected  void registerHooks()
          This method will be called whenever the view becomes active.
protected  void unregisterHooks()
          This method will be called whenever this view becomes inactive.
 void updateStackView()
           
 
Methods inherited from class gate.gui.docview.AbstractDocumentView
getActions, getDocument, getHandle, getOwner, isActive, setActive, setHandle, setOwner, setSelectedAnnotations, setTarget
 
Methods inherited from class gate.creole.AbstractResource
checkParameterValues, getBeanInfo, getName, getParameterValue, getParameterValue, init, removeResourceListeners, setName, setParameterValue, setParameterValue, setParameterValues, setParameterValues, setResourceListeners
 
Methods inherited from class gate.util.AbstractFeatureBearer
getFeatures, setFeatures
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface gate.Resource
getParameterValue, init, setParameterValue, setParameterValues
 
Methods inherited from interface gate.util.FeatureBearer
getFeatures, setFeatures
 
Methods inherited from interface gate.util.NameBearer
getName, setName
 

Field Detail

targetSetLabel

JLabel targetSetLabel

stackPanel

AnnotationStack stackPanel

scroller

JScrollPane scroller

mainPanel

JPanel mainPanel

textView

TextualDocumentView textView

annotationSetsView

AnnotationSetsView annotationSetsView

annotationListView

AnnotationListView annotationListView

targetSetName

String targetSetName

document

Document document

previousAnnotationAction

AnnotationStackView.PreviousAnnotationAction previousAnnotationAction

nextAnnotationAction

AnnotationStackView.NextAnnotationAction nextAnnotationAction

typesFeatures

Map<String,String> typesFeatures
optionally map a type to a feature when the feature value must be displayed in the rectangle annotation

Constructor Detail

AnnotationStackView

public AnnotationStackView()
Method Detail

cleanup

public void cleanup()
Description copied from class: AbstractResource
releases the memory allocated to this resource

Specified by:
cleanup in interface Resource
Overrides:
cleanup in class AbstractResource

initGUI

protected void initGUI()
Description copied from class: AbstractDocumentView
Implementers should override this method and use it for populating the GUI.

Specified by:
initGUI in class AbstractDocumentView

getGUI

public Component getGUI()
Description copied from interface: DocumentView
Returns the actual UI component this view represents.

Specified by:
getGUI in interface DocumentView
Returns:
a Component value.

initListeners

protected void initListeners()

registerHooks

protected void registerHooks()
Description copied from class: AbstractDocumentView
This method will be called whenever the view becomes active. Implementers should use this to add hooks (such as mouse listeners) to the other views as required by their functionality.

Specified by:
registerHooks in class AbstractDocumentView

unregisterHooks

protected void unregisterHooks()
Description copied from class: AbstractDocumentView
This method will be called whenever this view becomes inactive. Implementers should use it to unregister whatever hooks they registered in AbstractDocumentView.registerHooks().

Specified by:
unregisterHooks in class AbstractDocumentView

getType

public int getType()
Description copied from interface: DocumentView
Returns the type of this view.

Specified by:
getType in interface DocumentView
Returns:
an int value
See Also:
DocumentView.CENTRAL, DocumentView.HORIZONTAL, DocumentView.VERTICAL

annotationUpdated

public void annotationUpdated(AnnotationEvent e)
Description copied from interface: AnnotationListener
Called when an Annotation has been updated

Specified by:
annotationUpdated in interface AnnotationListener

updateStackView

public void updateStackView()

askTargetSet

boolean askTargetSet()
Returns:
true if the user input a valid annotation set