movecursor
Class AddressEdit

java.lang.Object
  extended by com.wrq.vhi.script.api.EntityEventHandler
      extended by movecursor.AddressEdit
All Implemented Interfaces:
com.wrq.vhi.script.api.EventHandler

public class AddressEdit
extends com.wrq.vhi.script.api.EntityEventHandler

Handle the move cursor event for the Address_edit entity.

This event handler moves the cursor between tabstops while writing attribute values. Handling the MoveCursor event bypasses the Verastream tabstop logic.

Without this event handler, the Verastream server will move the cursor between tabstops, and will write a new attribute value whenever it reaches a tabstop corresponding to an attribute that needs to be updated.

When using a MoveCursor event handler, Verastream will write the attribute values in an arbitrary order (usually the order in which the attributes were defined in the model). This is usually less optimal, unless the host application provides a way to quickly move between attributes.

The event handler logic is simple. Compare the current row the cursor is in and the desired row. Move the cursor forward or backward until it reaches the desired row. If the cursor is not in the desired column, use the find key to move it there.


Field Summary
static java.lang.String description
           
static int entityArrivalTimeout
          Timeout in seconds for the entityArrival() event.
static int entityDepartureTimeout
          Timeout in seconds for the entityDeparture() event.
static int moveCursorTimeout
          Timeout in seconds for the moveCursor() event.
static int writeAttributesTimeout
          Timeout in seconds for the writeAttributes() event.
 
Fields inherited from interface com.wrq.vhi.script.api.EventHandler
DEFAULT_TIMEOUT
 
Constructor Summary
AddressEdit()
           
 
Method Summary
 void moveCursor(com.wrq.vhi.script.api.EntityMoveCursorEvent event)
          Move the cursor to a tabstop.
 
Methods inherited from class com.wrq.vhi.script.api.EntityEventHandler
entityArrival, entityDeparture, writeAttributes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

description

public static final java.lang.String description
See Also:
Constant Field Values

entityArrivalTimeout

public static final int entityArrivalTimeout
Timeout in seconds for the entityArrival() event. A value of DEFAULT_TIMEOUT means the event will use the model defined default event timeout.

See Also:
Constant Field Values

entityDepartureTimeout

public static final int entityDepartureTimeout
Timeout in seconds for the entityDeparture() event. A value of DEFAULT_TIMEOUT means the event will use the model defined default event timeout.

See Also:
Constant Field Values

moveCursorTimeout

public static final int moveCursorTimeout
Timeout in seconds for the moveCursor() event. A value of DEFAULT_TIMEOUT means the event will use the model defined default event timeout.

See Also:
Constant Field Values

writeAttributesTimeout

public static final int writeAttributesTimeout
Timeout in seconds for the writeAttributes() event. A value of DEFAULT_TIMEOUT means the event will use the model defined default event timeout.

See Also:
Constant Field Values
Constructor Detail

AddressEdit

public AddressEdit()
Method Detail

moveCursor

public void moveCursor(com.wrq.vhi.script.api.EntityMoveCursorEvent event)
                throws com.wrq.apptrieve.agent.ApptrieveException
Move the cursor to a tabstop.

Overrides:
moveCursor in class com.wrq.vhi.script.api.EntityEventHandler
Parameters:
event - the event instance
Throws:
com.wrq.apptrieve.agent.ApptrieveException