public final class

NewObservationAction

extends ActionAdapter
java.lang.Object
   ↳ javax.swing.AbstractAction
     ↳ org.mbari.awt.event.ActionAdapter
       ↳ vars.annotation.ui.actions.NewObservationAction

Class Overview

Action to add a new VideoFrame and a 'nearly' empty Observation to the ObservationTable. Persistence is NOT done in the action but is handled by the table.

Summary

[Expand]
Inherited Constants
From interface javax.swing.Action
[Expand]
Inherited Fields
From class javax.swing.AbstractAction
Public Constructors
NewObservationAction(ToolBelt toolBelt)
Constructor for the NewVideoFrameAction object
Public Methods
void doAction()
Initiates the action.
Observation doAction(String conceptName)
Inserts a new Observation using the supplied conceptName.
Observation doAction(String conceptName, String timecode)
Inserts a new Observation using the supplied conceptName and timecode.
[Expand]
Inherited Methods
From class org.mbari.awt.event.ActionAdapter
From class javax.swing.AbstractAction
From class java.lang.Object
From interface java.awt.event.ActionListener
From interface javax.swing.Action
From interface org.mbari.awt.event.IAction

Public Constructors

public NewObservationAction (ToolBelt toolBelt)

Constructor for the NewVideoFrameAction object

Public Methods

public void doAction ()

Initiates the action. using the DEFAULT_CONCEPTNAME

See Also
  • org.mbari.awt.event.IAction

public Observation doAction (String conceptName)

Inserts a new Observation using the supplied conceptName. The new observation will be attached to a new VideoFrame if no matching time code was found. Otherwise a pre-existing videoFrame will be used. NOTE: The insertion and naming needs to be done in one step. Originally, the code was inserting an observation o f'object' then renaming it. However, during certain observations the row would not get moved to the newly inserted observation and we would end up renaming the wrong object.

Returns
  • The observation created. null if none was created.

public Observation doAction (String conceptName, String timecode)

Inserts a new Observation using the supplied conceptName and timecode. The new observation will be attached to a new VideoFrame if no matching time code was found. Otherwise a pre-existing videoFrame will be used.

Parameters
timecode A timecode in the format of HH:MM:SS:FF
Returns
  • The observation created. null if none was created.