Package com.thoughtworks.xstream.converters.basic

Examples of com.thoughtworks.xstream.converters.basic.AbstractSingleValueConverter


            xstream = new XStream();
        }

        // For any object whose elements contains an UTF8Buffer instance instead of a String
        // type we map it to String both in and out such that we don't marshal UTF8Buffers out
        xstream.registerConverter(new AbstractSingleValueConverter() {

            @Override
            public Object fromString(String str) {
                return str;
            }
View Full Code Here


            xstream = new XStream();
        }

        // For any object whose elements contains an UTF8Buffer instance instead of a String
        // type we map it to String both in and out such that we don't marshal UTF8Buffers out
        xstream.registerConverter(new AbstractSingleValueConverter() {

            @Override
            public Object fromString(String str) {
                return str;
            }
View Full Code Here

        }

        // For any object whose elements contains an UTF8Buffer instance instead
        // of a String type we map it to String both in and out such that we don't
        // marshal UTF8Buffers out
        xstream.registerConverter(new AbstractSingleValueConverter() {

            @Override
            public Object fromString(String str) {
                return str;
            }
View Full Code Here

        xstream.aliasField("file-extension", DocumentFormat.class, "fileExtension");
    xstream.aliasField("export-filters", DocumentFormat.class, "exportFilters");
    xstream.aliasField("export-options", DocumentFormat.class, "exportOptions");
        xstream.aliasField("import-options", DocumentFormat.class, "importOptions");
    xstream.alias("family", DocumentFamily.class);
    xstream.registerConverter(new AbstractSingleValueConverter() {
      public boolean canConvert(Class type) {
        return type.equals(DocumentFamily.class);
      }
      public Object fromString(String name) {
        return DocumentFamily.getFamily(name);
View Full Code Here

            xstream.ignoreUnknownElements();
        }

        // For any object whose elements contains an UTF8Buffer instance instead of a String
        // type we map it to String both in and out such that we don't marshal UTF8Buffers out
        xstream.registerConverter(new AbstractSingleValueConverter() {

            @Override
            public Object fromString(String str) {
                return str;
            }
View Full Code Here

TOP

Related Classes of com.thoughtworks.xstream.converters.basic.AbstractSingleValueConverter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.