com.wrq.vhi.script.api
Interface UpdateRecordEvent

All Superinterfaces:
EntityEvent, Event, HostSessionEvent, ModelEvent, RecordSetEvent

public interface UpdateRecordEvent
extends RecordSetEvent

Update record event information.

See Also:
RecordSetEventHandler.updateRecord(com.wrq.vhi.script.api.UpdateRecordEvent)

Method Summary
 void defaultUpdateRecord()
          Executes the before update operation, write the fields and then execute the after update operation.
 void defaultUpdateRecord(java.util.Map values)
          Executes the before update operation, write the fields and then execute the after update operation.
 java.util.Map getFieldWriteValues()
          Gets the set of fields and associated values to be written.
 void writeField(java.lang.String name, java.lang.String value)
          Writes the specified field to the current record on the screen.
 
Methods inherited from interface com.wrq.vhi.script.api.RecordSetEvent
getPageNumber, getRecordSetContext, getRecordSetMetaData, getRecordSetName
 
Methods inherited from interface com.wrq.vhi.script.api.EntityEvent
getEntityName, getTabStops
 
Methods inherited from interface com.wrq.vhi.script.api.HostSessionEvent
getHostSession
 
Methods inherited from interface com.wrq.vhi.script.api.ModelEvent
getClientSession, getCurrentOperation, getCurrentProcedure, getModelContext
 
Methods inherited from interface com.wrq.vhi.script.api.Event
checkForTimeout, createErrorMessage, createErrorMessage, createHostSession, createUserErrorMessage, getEventStack, getHandlerProperty, getLogger, isDesignEnvironment
 

Method Detail

getFieldWriteValues

java.util.Map getFieldWriteValues()
Gets the set of fields and associated values to be written. The values in the map can be modified and the map used as a parameter to the defaultUpdateRecord(java.util.Map) method.

Returns:
A map of field names to field values

writeField

void writeField(java.lang.String name,
                java.lang.String value)
                throws ApptrieveException
Writes the specified field to the current record on the screen. If the cursor is not at the field's location, the VHI will issue a MoveCursor command. Upon successfully moving the cursor, the value will be written to the screen, firing the appropriate FieldEventHandler.writeField(com.wrq.vhi.script.api.WriteFieldEvent) event, if any.

Parameters:
name - the field name
value - the field value
Throws:
ApptrieveException

defaultUpdateRecord

void defaultUpdateRecord()
                         throws ApptrieveException
Executes the before update operation, write the fields and then execute the after update operation. The field values returned by getFieldWriteValues() will be used.

Throws:
ApptrieveException

defaultUpdateRecord

void defaultUpdateRecord(java.util.Map values)
                         throws ApptrieveException
Executes the before update operation, write the fields and then execute the after update operation.

Parameters:
values - the fields and values to update
Throws:
ApptrieveException