Services Builder for Screens

com.attachmate.sc.ssa
Interface IFieldData


public interface IFieldData

This interface describes a host field. The methods interact with the host field, allowing the getting and setting of text as well as the location and length of the field. All the attributes have been normalized to be generic between all host types.


Method Summary
 long[] getAttributes()
          Returns all the attributes for every position in the field.
 long getFieldAttribute()
          Returns the field attribute for the field.
 int getLength()
          Returns the length of this field, including field attributes.
 Point getScreenPosition()
          Returns the starting position of this field on the screen
 java.lang.String getText()
          Returns the field text as a string
 boolean isAttribSpace()
          Indicates whether field attributes occupy space on the screen.
 boolean isModified()
          Indicates whether field has been modified.
 void setText(java.lang.String text)
          Sets field text to the specified value.
 

Method Detail

getScreenPosition

public Point getScreenPosition()
Returns the starting position of this field on the screen

Returns:
the column, row coordinates of this field

getLength

public int getLength()
Returns the length of this field, including field attributes. To determine the text length, use String.length on the string returned by getText.

Returns:
the number of elements in this field
See Also:
getText( )

isModified

public boolean isModified()
Indicates whether field has been modified. The field is considered modified if someone calls setText on this field.

Returns:
true if the field has been modified

isAttribSpace

public boolean isAttribSpace()
Indicates whether field attributes occupy space on the screen.

Returns:
true if field attributes occupy screen space

getFieldAttribute

public long getFieldAttribute()
Returns the field attribute for the field. The value of the attribute can be determined by using the attribute definitions in IQAScreenConstants.

Returns:
the attribute for the field.

getAttributes

public long[] getAttributes()
Returns all the attributes for every position in the field. The value of the attributes can be determined by using the attribute definitions in IQAScreenConstants.

Returns:
an array of attribute for each posistion for this field.

setText

public void setText(java.lang.String text)
             throws ProtectedFieldException
Sets field text to the specified value. Replaces characters up to field length or string length, whichever is lesser. If the string is shorter than the field, pads the remaining characters with Unicode null.

Parameters:
text - the new field text
Throws:
ProtectedFieldException - if an attempt is made to set text on a protected field

getText

public java.lang.String getText()
Returns the field text as a string

Returns:
the field text

Services Builder for Screens