1 | boolean canConvert(Class arg0) {↵ | | 1 | boolean canConvert(Class arg0) {↵
|
2 | return arg0.equals(LongProperty.class);↵ | | 2 | return arg0.equals(IntegerProperty.class);↵
|
3 | }↵ | | 3 | }↵
|
|
4 | /*↵ | | 4 | /*↵
|
5 | * (non-Javadoc)↵ | | 5 | * (non-Javadoc)↵
|
6 | * ↵ | | 6 | * ↵
|
7 | * @see com.thoughtworks.xstream.converters.Converter#marshal(java.lang.Object,↵ | | 7 | * @see com.thoughtworks.xstream.converters.Converter#marshal(java.lang.Object,↵
|
8 | * com.thoughtworks.xstream.io.HierarchicalStreamWriter,↵ | | 8 | * com.thoughtworks.xstream.io.HierarchicalStreamWriter,↵
|
9 | * com.thoughtworks.xstream.converters.MarshallingContext)↵ | | 9 | * com.thoughtworks.xstream.converters.MarshallingContext)↵
|
10 | */↵ | | 10 | */↵
|
11 | public void marshal(Object obj, HierarchicalStreamWriter writer, MarshallingContext arg2) {↵ | | 11 | public void marshal(Object obj, HierarchicalStreamWriter writer, MarshallingContext arg2) {↵
|
12 | LongProperty prop = (LongProperty) obj;↵ | | 12 | IntegerProperty prop = (IntegerProperty) obj;↵
|
13 | writer.addAttribute(ATT_NAME, ConversionHelp.encode(prop.getName()));↵ | | 13 | writer.addAttribute(ATT_NAME, ConversionHelp.encode(prop.getName()));↵
|
14 | writer.setValue(prop.getStringValue());↵ | | 14 | writer.setValue(prop.getStringValue());↵
|
15 | } | | 15 | }
|