Javadoc fix.
This commit is contained in:
@@ -47,16 +47,16 @@ import net.sf.json.JSONObject;
|
||||
* Config cfg = new Config();
|
||||
* System.out.println(cfg.convert(new Pojo()));
|
||||
* </pre>
|
||||
* Converting a type universally: <pre>
|
||||
* Converting a type universally: <pre>{@code
|
||||
Converter<Color> colorConv = new Converter<Color>() {
|
||||
public Object convert (Color c, Config cfg) {
|
||||
return new Integer((c.getRed() << 16) | (c.getGreen()<<8) | c.getBlue());
|
||||
return new Integer((c.getRed() << 16) | (c.getGreen() << 8) | c.getBlue());
|
||||
}
|
||||
};
|
||||
|
||||
cfg.addClassConverter(Color.class, colorConv);
|
||||
* </pre>
|
||||
* Customizing a specific field of a class:<pre>
|
||||
* }</pre>
|
||||
* Customizing a specific field of a class:<pre>{@code
|
||||
FieldAccessor<SomeImpl, Collection<?>> entryConv =
|
||||
new FieldAccessor<SomeImpl, Collection<?>>() {
|
||||
public Collection<SomeValue> get (SomeImpl impl) {
|
||||
@@ -66,7 +66,7 @@ import net.sf.json.JSONObject;
|
||||
cfg.addFieldConfig(SomeImpl.class, new FieldConfig<SomeImpl>().
|
||||
addExclusions("privateStuff").
|
||||
addFieldConverter("valueMap", new ConvertCollectionFieldToArray<SomeImpl>(entryConv)));
|
||||
* </pre>
|
||||
* }</pre>
|
||||
*/
|
||||
public class JSONConversion
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user