com.bowstreet.xml.schema
Class SchemaUtils
java.lang.Object
com.bowstreet.xml.schema.SchemaUtils
public class SchemaUtils
- extends java.lang.Object
Utility class for working with XML Schema
-
Method Summary |
static java.lang.String |
concatPath(java.lang.String first,
java.lang.String second)
|
static java.lang.String |
concatPath(java.lang.String first,
java.lang.String second,
java.lang.String absolutePath,
java.lang.String schemaURL)
|
static java.lang.String |
findRelativePath(java.lang.String schemaLocation,
java.lang.String parentBase)
|
static java.lang.String |
getLocationFromURL(java.lang.String url)
|
static java.lang.String |
getXSDType(java.lang.String javaType)
Gets XSD name for the specified Java Type |
static java.lang.String |
getXSDType(java.lang.String javaType,
boolean defaultToString)
Gets XSD name for the specified Java Type |
static void |
initXSDTypes()
initialize the java to XSD type map. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
forwardslash
public static final java.lang.String forwardslash
- See Also:
- Constant Field Values
SchemaUtils
public SchemaUtils()
concatPath
public static java.lang.String concatPath(java.lang.String first,
java.lang.String second)
concatPath
public static java.lang.String concatPath(java.lang.String first,
java.lang.String second,
java.lang.String absolutePath,
java.lang.String schemaURL)
findRelativePath
public static java.lang.String findRelativePath(java.lang.String schemaLocation,
java.lang.String parentBase)
throws java.io.IOException
- Throws:
java.io.IOException
getLocationFromURL
public static java.lang.String getLocationFromURL(java.lang.String url)
getXSDType
public static java.lang.String getXSDType(java.lang.String javaType)
- Gets XSD name for the specified Java Type
- Parameters:
javaType
- the Java type (e.g. boolean, String)
- Returns:
- The XSD name, defaults to "string" if no XSD type was found.
getXSDType
public static java.lang.String getXSDType(java.lang.String javaType,
boolean defaultToString)
- Gets XSD name for the specified Java Type
- Parameters:
javaType
- the Java type (e.g. boolean, String)defaultToString
- Specifies if no xsd type found to default return value to "string".
- Returns:
- The XSD name.
initXSDTypes
public static void initXSDTypes()
- initialize the java to XSD type map.
Copyright © 2009 IBM. All Rights Reserved.