undo a little formatting mayhem
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@598710 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
55817e2233
commit
b124f18766
|
@ -22,9 +22,9 @@ import java.text.ParseException;
|
||||||
import java.text.ParsePosition;
|
import java.text.ParsePosition;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Formats using one formatter and parses using a different formatter.
|
* Formats using one formatter and parses using a different formatter. An
|
||||||
* An example of use for this would be a webapp where data is taken in one way
|
* example of use for this would be a webapp where data is taken in one way and
|
||||||
* and stored in a database another way.
|
* stored in a database another way.
|
||||||
*
|
*
|
||||||
* @author Archimedes Trajano
|
* @author Archimedes Trajano
|
||||||
* @version $Id$
|
* @version $Id$
|
||||||
|
@ -58,33 +58,29 @@ public class CompositeFormat extends Format {
|
||||||
/**
|
/**
|
||||||
* Uses the formatter Format instance.
|
* Uses the formatter Format instance.
|
||||||
*
|
*
|
||||||
* @param obj
|
* @param obj the object to format
|
||||||
* the object to format
|
* @param toAppendTo the {@link StringBuffer} to append to
|
||||||
* @param toAppendTo
|
* @param pos the FieldPosition to use (or ignore).
|
||||||
* the {@link StringBuffer} to append to
|
|
||||||
* @param pos
|
|
||||||
* the FieldPosition to use (or ignore).
|
|
||||||
* @return <code>toAppendTo</code>
|
* @return <code>toAppendTo</code>
|
||||||
* @see Format#format(Object, StringBuffer, FieldPosition)
|
* @see Format#format(Object, StringBuffer, FieldPosition)
|
||||||
*/
|
*/
|
||||||
public StringBuffer format(Object obj, StringBuffer toAppendTo, FieldPosition pos) {
|
public StringBuffer format(Object obj, StringBuffer toAppendTo,
|
||||||
return formatter.format(obj,toAppendTo,pos);
|
FieldPosition pos) {
|
||||||
|
return formatter.format(obj, toAppendTo, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Uses the parser Format instance.
|
* Uses the parser Format instance.
|
||||||
*
|
*
|
||||||
* @param source
|
* @param source the String source
|
||||||
* the String source
|
* @param pos the ParsePosition containing the position to parse from, will
|
||||||
* @param pos
|
|
||||||
* the ParsePosition containing the position to parse from, will
|
|
||||||
* be updated according to parsing success (index) or failure
|
* be updated according to parsing success (index) or failure
|
||||||
* (error index)
|
* (error index)
|
||||||
* @return the parsed Object
|
* @return the parsed Object
|
||||||
* @see Format#parseObject(String, ParsePosition)
|
* @see Format#parseObject(String, ParsePosition)
|
||||||
*/
|
*/
|
||||||
public Object parseObject(String source, ParsePosition pos) {
|
public Object parseObject(String source, ParsePosition pos) {
|
||||||
return parser.parseObject(source,pos);
|
return parser.parseObject(source, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue