org.jclarion.clarion.runtime.format
Class PatternFormat
java.lang.Object
org.jclarion.clarion.runtime.format.Formatter
org.jclarion.clarion.runtime.format.PatternFormat
public class PatternFormat
- extends Formatter
Decode a pattern
format is
'#' - match a number - if no number render '0'
'<' - match a number or blank
. - match exact character
Pattern decoding is made complicated by fact that '<'
is optional - so multiple decoding paths can exist. Solution needs
to employ recursion to discover correct path
- Author:
- barney
| Fields inherited from class org.jclarion.clarion.runtime.format.Formatter |
picture |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PatternFormat
public PatternFormat(java.lang.String pattern)
deformat
public java.lang.String deformat(java.lang.String input)
- Specified by:
deformat in class Formatter
format
public boolean format(FormatResolver fr)
format
public java.lang.String format(java.lang.String input)
- Specified by:
format in class Formatter
getMaxLen
public int getMaxLen()
- Specified by:
getMaxLen in class Formatter
getPictureRepresentation
public java.lang.String getPictureRepresentation()
- Specified by:
getPictureRepresentation in class Formatter
Copyright © 2010. All Rights Reserved.