private static XmlObject newValue(SchemaType st, String value) { try { return st.newValue(value); } catch (IllegalArgumentException e) { // This is a bit hacky. newValue throws XmlValueOutOfRangeException which is // unchecked and declared in typeimpl. I can only catch its parent class, // typeimpl is built after common. // Ignore these exceptions. Assume that validation will catch them. return null; } }
/** Creates an immutable {@link XmlPositiveInteger} value */ public static XmlPositiveInteger newValue(Object obj) { return (XmlPositiveInteger) type.newValue( obj ); }
/** Creates an immutable {@link XmlByte} value */ public static XmlByte newValue(Object obj) { return (XmlByte) type.newValue( obj ); }
/** Creates an immutable {@link XmlBoolean} value */ public static XmlBoolean newValue(Object obj) { return (XmlBoolean) type.newValue( obj ); }
/** Creates an immutable {@link XmlTime} value */ public static XmlTime newValue(Object obj) { return (XmlTime) type.newValue( obj ); }
/** Creates an immutable {@link XmlGYearMonth} value */ public static XmlGYearMonth newValue(Object obj) { return (XmlGYearMonth) type.newValue( obj ); }
/** Creates an immutable {@link XmlNCName} value */ public static XmlNCName newValue(Object obj) { return (XmlNCName) type.newValue( obj ); }
/** Creates an immutable {@link XmlGYear} value */ public static XmlGYear newValue(Object obj) { return (XmlGYear) type.newValue( obj ); }
/** Creates an immutable {@link XmlNMTOKENS} value */ public static XmlNMTOKENS newValue(Object obj) { return (XmlNMTOKENS) type.newValue( obj ); }
/** Creates an immutable {@link XmlGMonth} value */ public static XmlGMonth newValue(Object obj) { return (XmlGMonth) type.newValue( obj ); }
/** Creates an immutable {@link XmlNegativeInteger} value */ public static XmlNegativeInteger newValue(Object obj) { return (XmlNegativeInteger) type.newValue( obj ); }
/** Creates an immutable {@link XmlHexBinary} value */ public static XmlHexBinary newValue(Object obj) { return (XmlHexBinary) type.newValue( obj ); }
/** Creates an immutable {@link XmlInt} value */ public static XmlInt newValue(Object obj) { return (XmlInt) type.newValue( obj ); }
/** Creates an immutable {@link XmlDateTime} value */ public static XmlDateTime newValue(Object obj) { return (XmlDateTime) type.newValue( obj ); }
/** Creates an immutable {@link XmlDuration} value */ public static XmlDuration newValue(Object obj) { return (XmlDuration) type.newValue( obj ); }
/** Creates an immutable {@link XmlObject} value */ public static XmlObject newValue ( Object obj ) { return type.newValue( obj ); }
/** Creates an immutable {@link XmlENTITY} value */ public static XmlENTITY newValue(Object obj) { return (XmlENTITY) type.newValue( obj ); }
/** Creates an immutable {@link XmlID} value */ public static XmlID newValue(Object obj) { return (XmlID) type.newValue( obj ); }
/** Creates an immutable {@link XmlString} value */ public static XmlString newValue(Object obj) { return (XmlString) type.newValue( obj ); }
/** Creates an immutable {@link XmlAnyURI} value */ public static XmlAnyURI newValue(Object obj) { return (XmlAnyURI) type.newValue( obj ); }