HATS 7.5.1 Web API Reference

Publicly accessible methods not documented here are for IBM internal use only and may change in a future release of the product.

com.ibm.hats.transform.components
Class DialogComponent

java.lang.Object
  extended by com.ibm.hats.transform.components.Component
      extended by com.ibm.hats.transform.components.DialogComponent
All Implemented Interfaces:
IContextDependent, ICustomPropertySupplier
Direct Known Subclasses:
EnptuiWindowComponent

public class DialogComponent
extends Component
implements IContextDependent

The Dialog component is responsible for recognizing pop-ups (also known as modals or dialogs) in a specified region of a host screen.

A recognized dialog can be rendered by the following widgets:

The recognize() methods of this component return ComponentElement objects of type: The following settings can be configured for this component:

PropertyDescriptionTypeDefault Value
horizontalBorderThe attributed string which contains the choice characters of the top and bottom of the dialogString{p rv}|.|-|_
verticalBorderThe attributed string which contains the choice characters of the sides of the dialogString{p rv}|:|&vl.
validateCursorWhether the cursor has to be inside of the dialogBooleantrue
interactWhether or not the area outside of the border should be disabledBooleantrue
matchSidesWhether or not the sides of the dialog should matchBooleantrue
takeFirstMatchwhether or not to keep looking once we find a match, only valid when validateCursor is falseBooleantrue
interactWhether or not the area outside of the border should be disabledBooleantrue
acceptOutsideCursorAtIf the cursor is in a position where there is no dialog, the cursor default location if there is a dialog. Useful for pages where the cursor defaults to an area because there is no input fieldNumberedSet1
minColsthe minimum amount of columns to consider an area to be a DialogInteger3
minRowsthe minimum amount of rows to consider an area to be a DialogInteger3

See Also:
DialogRowComponentElement, DisabledAreaComponentElement, FieldRowComponentElement, BasicDialogWidget

Field Summary
static int BOTTOM_BORDER
           
static int BOTTOMLEFTCORNER_BORDER
           
static int BOTTOMRIGHTCORNER_BORDER
           
static String CLASS
           
static String CLASS_NAME
           
static Properties defaults
           
static int LEFT_BORDER
           
static String PROPERTY_ALLOW_EXTERNAL_INTERACTION
           
static String PROPERTY_CURSOR_AT_ORIGIN
           
static String PROPERTY_CURSORLOGIC
           
static String PROPERTY_HORIZONTAL_CHARS
           
static String PROPERTY_MATCH_SIDES
           
static String PROPERTY_MINIMUM_COLS
           
static String PROPERTY_MINIMUM_ROWS
           
static String PROPERTY_MINIMUM_TOP_HEADER_CHARS
           
static String PROPERTY_SEARCHMORE
           
static String PROPERTY_TAKE_FIRST_MATCH
           
static String PROPERTY_VALIDATE_CURSOR
           
static String PROPERTY_VERTICAL_CHARS
           
static int RIGHT_BORDER
           
static int TOP_BORDER
           
static int TOPLEFTCORNER_BORDER
           
static int TOPRIGHTCORNER_BORDER
           
static String VALUE_HALF_LENGTH
           
 
Fields inherited from class com.ibm.hats.transform.components.Component
contextAttributes, flag, hostScreen
 
Fields inherited from interface com.ibm.hats.common.ICustomPropertySupplier
CLASSNAME
 
Constructor Summary
DialogComponent(HsrScreen hostScreen)
          Constructs a new DialogComponent object.
 
Method Summary
 Vector getCustomProperties(int iPageNumber, Properties properties, ResourceBundle bundle)
          Returns a list of this object's custom properties.
 Properties getDefaultValues(int iPageNumber)
          Returns this object's default property values.
 int getPropertyPageCount()
          Returns the number of property pages associated with this object.
 boolean isAllowed(ContextAttributes contextAttributes)
          Gets whether or not this object should be visible in the studio given some context attributes.
 boolean isPropertyAllowed(String name, ContextAttributes contextAttributes)
          Gets whether or not the specified property should be visible in the component or widget settings.
 ComponentElement[] recognize(BlockScreenRegion region, Properties settings)
          Returns an array of ComponentElement objects representing the screen of the area found as the border and outside of the dialog.
 ComponentElement[] recognize(com.ibm.hats.transform.regions.LinearScreenRegion region, Properties settings)
          Not currently implemented.
 
Methods inherited from class com.ibm.hats.transform.components.Component
convertPosToCol, convertPosToRow, convertRowColToPos, findFirstDelimiterIndex, findFirstIndexOf, findFirstIndexOf, findFirstIndexOf, findFirstNonWhitespaceIndex, findFirstNonWhitespaceIndex, findFirstNonWhitespaceIndex, getContextAttribute, getContextAttributes, getCustomComposite, getHostScreen, getTrailingSpaceCount, newInstance, recognize, setContextAttribute, setContextAttributes, setHostScreen
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_NAME

public static final String CLASS_NAME
See Also:
Constant Field Values

CLASS

public static final String CLASS
See Also:
Constant Field Values

PROPERTY_HORIZONTAL_CHARS

public static final String PROPERTY_HORIZONTAL_CHARS
See Also:
Constant Field Values

PROPERTY_VERTICAL_CHARS

public static final String PROPERTY_VERTICAL_CHARS
See Also:
Constant Field Values

PROPERTY_ALLOW_EXTERNAL_INTERACTION

public static final String PROPERTY_ALLOW_EXTERNAL_INTERACTION
See Also:
Constant Field Values

PROPERTY_VALIDATE_CURSOR

public static final String PROPERTY_VALIDATE_CURSOR
See Also:
Constant Field Values

LEFT_BORDER

public static final int LEFT_BORDER
See Also:
Constant Field Values

TOP_BORDER

public static final int TOP_BORDER
See Also:
Constant Field Values

RIGHT_BORDER

public static final int RIGHT_BORDER
See Also:
Constant Field Values

BOTTOM_BORDER

public static final int BOTTOM_BORDER
See Also:
Constant Field Values

TOPLEFTCORNER_BORDER

public static final int TOPLEFTCORNER_BORDER
See Also:
Constant Field Values

TOPRIGHTCORNER_BORDER

public static final int TOPRIGHTCORNER_BORDER
See Also:
Constant Field Values

BOTTOMLEFTCORNER_BORDER

public static final int BOTTOMLEFTCORNER_BORDER
See Also:
Constant Field Values

BOTTOMRIGHTCORNER_BORDER

public static final int BOTTOMRIGHTCORNER_BORDER
See Also:
Constant Field Values

defaults

public static Properties defaults

PROPERTY_MATCH_SIDES

public static final String PROPERTY_MATCH_SIDES
See Also:
Constant Field Values

PROPERTY_TAKE_FIRST_MATCH

public static final String PROPERTY_TAKE_FIRST_MATCH
See Also:
Constant Field Values

PROPERTY_CURSOR_AT_ORIGIN

public static final String PROPERTY_CURSOR_AT_ORIGIN
See Also:
Constant Field Values

PROPERTY_MINIMUM_COLS

public static final String PROPERTY_MINIMUM_COLS
See Also:
Constant Field Values

PROPERTY_MINIMUM_ROWS

public static final String PROPERTY_MINIMUM_ROWS
See Also:
Constant Field Values

PROPERTY_MINIMUM_TOP_HEADER_CHARS

public static final String PROPERTY_MINIMUM_TOP_HEADER_CHARS
See Also:
Constant Field Values

PROPERTY_CURSORLOGIC

public static final String PROPERTY_CURSORLOGIC
See Also:
Constant Field Values

PROPERTY_SEARCHMORE

public static final String PROPERTY_SEARCHMORE
See Also:
Constant Field Values

VALUE_HALF_LENGTH

public static final String VALUE_HALF_LENGTH
See Also:
Constant Field Values
Constructor Detail

DialogComponent

public DialogComponent(HsrScreen hostScreen)
Constructs a new DialogComponent object.

Method Detail

isPropertyAllowed

public boolean isPropertyAllowed(String name,
                                 ContextAttributes contextAttributes)
Description copied from interface: IContextDependent
Gets whether or not the specified property should be visible in the component or widget settings. The context attributes may contain the Component name when this is called on a Widget, or whether or not we are presenting this Component/Widget choice while configuring Default Rendering.

Specified by:
isPropertyAllowed in interface IContextDependent
Parameters:
name - property name
Returns:
whether or not this property is allowed in the specified context

isAllowed

public boolean isAllowed(ContextAttributes contextAttributes)
Description copied from interface: IContextDependent
Gets whether or not this object should be visible in the studio given some context attributes. The context attributes may contain the Component name when this is called on a Widget, or whether or not we are presenting this Component/Widget choice while configuring Default Rendering.

Specified by:
isAllowed in interface IContextDependent
Returns:
whether or not this Component or Widget is allowed in the specified context

recognize

public ComponentElement[] recognize(com.ibm.hats.transform.regions.LinearScreenRegion region,
                                    Properties settings)
Not currently implemented. The dialog is considered a block-style recognition.

Specified by:
recognize in class Component
See Also:
Component.recognize(LinearScreenRegion, Properties)

recognize

public ComponentElement[] recognize(BlockScreenRegion region,
                                    Properties settings)
Returns an array of ComponentElement objects representing the screen of the area found as the border and outside of the dialog. The internal window will be recognized if the dialog is used as standalone by the FieldComponent, otherwise the area will be left for use by other Components.

Specified by:
recognize in class Component
Parameters:
region - BlockScreenRegion to search in
settings - recognition settings
Returns:
an array of ComponentElement objects.
See Also:
Component.recognize(BlockScreenRegion, Properties), DialogRowComponentElement, DisabledAreaComponentElement, FieldComponent, FieldRowComponentElement

getPropertyPageCount

public int getPropertyPageCount()
Description copied from interface: ICustomPropertySupplier
Returns the number of property pages associated with this object.

Note: Currently only 0 or 1 pages are supported.

Specified by:
getPropertyPageCount in interface ICustomPropertySupplier
Overrides:
getPropertyPageCount in class Component
Returns:
the number of defined property pages used to configure this object, or 0 if there are none

getCustomProperties

public Vector getCustomProperties(int iPageNumber,
                                  Properties properties,
                                  ResourceBundle bundle)
Description copied from interface: ICustomPropertySupplier
Returns a list of this object's custom properties. Items must be of type com.ibm.hats.common.HCustomProperty.

Specified by:
getCustomProperties in interface ICustomPropertySupplier
Overrides:
getCustomProperties in class Component
Parameters:
iPageNumber - page number containing desired properties
properties - existing values for properties defined here
bundle - ResourceBundle containing NLS descriptions for the properties
Returns:
Vector containing all the custom properties for this object, or null if there are none
See Also:
HCustomProperty

getDefaultValues

public Properties getDefaultValues(int iPageNumber)
Description copied from interface: ICustomPropertySupplier
Returns this object's default property values.

Specified by:
getDefaultValues in interface ICustomPropertySupplier
Overrides:
getDefaultValues in class Component
Parameters:
iPageNumber - page for which to retrieve default properties
Returns:
object's default properties

HATS 7.5.1 (201005110649)