UIX 2.2.15

oracle.cabo.ui.validate
Class WMLPatternValidater

java.lang.Object
  |
  +--oracle.cabo.ui.validate.BaseClientValidater
        |
        +--oracle.cabo.ui.validate.WMLPatternValidater
All Implemented Interfaces:
ClientValidater, Formatter, ServerValidater

public class WMLPatternValidater
extends BaseClientValidater
implements Formatter

A Validater that validates Strings using the WML text input patterns. This is the only pattern capable of validating on both HTML and WML, making it a good choice for simple validation in components that will be used in both Systems.

The pattern is formed of the following format characters:

A Entry of any upper-case alphabetic or punctuation character (i.e., upper-case non-numeric character).
a Entry of any lower-case alphabetic or punctuation character (i.e., lower-case non-numeric character).
N Entry of any numeric character.
X Entry of any upper case character.
x Entry of any lower-case character.
M Entry of any character; the user agent may choose to assume that the character is upper-case for the purposes of simple data entry, but must allow entry of any character.
m Entry of any character; the user agent may choose to assume that the character is lower-case for the purposes of simple data entry, but must allow entry of any character.
*f Entry of any number of characters; f is one of the above format codes and specifies what kind of characters can be entered.

Note:This format may only be specified once and must appear at the end of the format string.

nf Entry of up to n characters where n is from 1 to 9; f is one of the above format codes (other than *f format code) and specifies what kind of characters can be entered.

Note:This format may only be specified once and must appear at the end of the format string.

\c</c> Display the next character, c, in the entry field; allows escaping of the format codes as well as introducing non-formatting characters so they can be displayed in the entry area. Escaped characters are considered part of the input's value, and must be preserved by the user agent. For example, the stored value of the input "12345-123" having a mask "NNNNN\-3N" is "12345-123" and not "12345123".

Fields inherited from interface oracle.cabo.ui.validate.ServerValidater
NO_CONTENT_ERROR_OFFSET, UNKNOWN_ERROR_OFFSET
Constructor Summary
WMLPatternValidater()
WMLPatternValidater(java.lang.String pattern)
Method Summary
java.lang.String formatObject(java.lang.Object value, LocaleContext localeContext)
Bogus implementation.
protected java.lang.String getHTMLLibReference()
Returns the name of the Javascript code that this validator requires.
protected java.lang.String getHTMLValidation(RenderingContext context)
java.lang.String getPattern()
Returns the patter used to vlaidate the input.
protected java.lang.String getWMLValidation(RenderingContext context)
java.lang.Object parseString(java.lang.String parseString, LocaleContext localeContext)
Returns the value String minus any escaped constants.
java.text.ParseException[] validate(RenderingContext context, java.lang.String value)
Methods inherited from class oracle.cabo.ui.validate.BaseClientValidater
getLookAndFeelString, getValidation, getValidationFormat, logError, writeDependencies
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

WMLPatternValidater

public WMLPatternValidater()

WMLPatternValidater

public WMLPatternValidater(java.lang.String pattern)
Method Detail

getPattern

public final java.lang.String getPattern()
Returns the patter used to vlaidate the input.

validate

public java.text.ParseException[] validate(RenderingContext context,
                                           java.lang.String value)

formatObject

public java.lang.String formatObject(java.lang.Object value,
                                     LocaleContext localeContext)
Bogus implementation.
Specified by:
formatObject in interface Formatter

parseString

public java.lang.Object parseString(java.lang.String parseString,
                                    LocaleContext localeContext)
                             throws java.text.ParseException
Returns the value String minus any escaped constants.
Specified by:
parseString in interface Formatter

getHTMLValidation

protected java.lang.String getHTMLValidation(RenderingContext context)
Overrides:
getHTMLValidation in class BaseClientValidater

getWMLValidation

protected java.lang.String getWMLValidation(RenderingContext context)
Overrides:
getWMLValidation in class BaseClientValidater

getHTMLLibReference

protected java.lang.String getHTMLLibReference()
Returns the name of the Javascript code that this validator requires.
Overrides:
getHTMLLibReference in class BaseClientValidater

UIX 2.2.15