borland Packages Class Hierarchy dx.text Package
ItemEditMaskStr class
java.lang.Object
+----com.borland.dx.text.ItemEditMaskStr
About the ItemEditMaskStr class
Constructors Properties Methods
Implements ItemEditMask, ItemEditMaskRegionChar, Serializable
The ItemEditMaskStr class implements the ItemEditMask interface using pattern strings to control formatting, parsing, and edit interactions.
For information about constructing an edit mask, see string-based patterns.
ItemEditMaskStr constructors
ItemEditMaskStr properties
*Read-only properties **Write-only properties
Properties implemented in java.lang.Object
ItemEditMaskStr methods
Methods implemented in this class
- delete(com.borland.dx.text.ItemEditMaskState, int, int)
- deleteCharAt(java.lang.StringBuffer, int, char)
- getCharAt(java.lang.StringBuffer, int)
- getFinalValue(com.borland.dx.text.ItemEditMaskState, com.borland.dx.dataset.Variant)
- getFinalValue(com.borland.dx.text.ItemEditMaskState, com.borland.dx.dataset.Variant, int)
- insert(com.borland.dx.text.ItemEditMaskState, char)
- isComplete(com.borland.dx.text.ItemEditMaskState)
- isLiteral(int)
- isOptional(int)
- isPassword(int)
- isValid(int, char)
- literalAt(int)
- move(com.borland.dx.text.ItemEditMaskState, int)
- prepare(com.borland.dx.dataset.Variant)
- setCharAt(java.lang.StringBuffer, int, char)
- shiftLeft(com.borland.dx.text.ItemEditMaskState)
Methods implemented in java.lang.Object
- clone()
- equals(java.lang.Object)
- finalize()
- hashCode()
- notify()
- notifyAll()
- toString()
- wait()
- wait(long)
- wait(long, int)
ItemEditMaskStr constructors
ItemEditMaskStr(java.lang.String, com.borland.dx.text.VariantFormatter, int)
public ItemEditMaskStr(String editMask, VariantFormatter formatter, int variantType)
Constructs an ItemEditMaskStr object which implements a string-based ItemEditMask.
You do not need to construct an ItemEditMask for every text field, only those for which you want to constrain input on a character-by-character basis.
Parameters:
- editMask
- Contains a String which controls the character-by-character editing semantics when used by a text control. If null or empty, it inherits the formatMask from the formatter parameter.
- formatter
- The VariantFormatter object used by this class. If this parameter is null, a default one will be constructed from the other parameters.
- variantType
- Contains one of the values defined in Variant. variantType defines the type of data returned from the getValue() method. If it is zero, variantType defaults to that of the formatter.
See also: VariantFormatStr, ItemEditMask
ItemEditMaskStr(java.lang.String, com.borland.dx.text.VariantFormatter, int, java.util.Locale)
public ItemEditMaskStr(String editMask, VariantFormatter formatter, int variantType, Locale locale)
Constructs an ItemEditMaskStr object which implements a string-based ItemEditMask.
You do not need to construct an ItemEditMask for every text field, only those for which you want to constrain input on a character-by-character basis.
Parameters:
- editMask
- Contains a String which controls the character-by-character editing semantics when used by a text control. If null or empty, it inherits the formatMask from the formatter parameter.
- formatter
- The VariantFormatter object used by this class. If this parameter is null, a default one will be constructed from the other parameters.
- variantType
- Contains one of the values defined in Variant. variantType defines the type of data returned from the getValue() method. If it is zero, variantType defaults to that of the formatter.
- locale
- Contains the locale to use. If null, the Locale of the formatter object is used. If formatter is also null, the current machine's default locale is used.
See also: VariantFormatStr, ItemEditMask
ItemEditMaskStr methods
isPassword(int)
public boolean isPassword(int charPosition)
Returns true if the indicated character position in the edit mask is to be treated as a password character. This is determined by the presence of "*" (the password symbol) in the edit mask.
See String-based patterns for details.
Parameters:
- charPosition
- A character position in the edit mask.
literalAt(int)
public char literalAt(int charPosition)
Returns the literal character at the specified character position.
Parameters:
- charPosition
- A character position in the edit mask.
shiftLeft(com.borland.dx.text.ItemEditMaskState)
protected boolean shiftLeft(ItemEditMaskState state)
Shifts the entire contents of the edit buffer left by one position. It stops when it hits an illegal situation (such as moving a letter into a digit field). It also stops at the first character in the string; that is, it doesn't drop characters off the left. It starts at the state.cursorPos. If that cursorPos is at a valid character, it converts that character into
a blankChar. Blank characters are not shifted, so the first blank character stops the shift.
Parameters:
- state
- The edit mask state of the control.