1 16 17 package org.apache.xerces.impl.dv; 18 19 import org.apache.xerces.util.SymbolHash; 20 import org.apache.xerces.xs.XSObjectList; 21 22 40 public abstract class SchemaDVFactory { 41 42 private static final String DEFAULT_FACTORY_CLASS = "org.apache.xerces.impl.dv.xs.SchemaDVFactoryImpl"; 43 44 51 public static synchronized final SchemaDVFactory getInstance() throws DVFactoryException { 52 return getInstance(DEFAULT_FACTORY_CLASS); 53 } 55 56 64 public static synchronized final SchemaDVFactory getInstance(String factoryClass) throws DVFactoryException { 65 66 try { 67 return (SchemaDVFactory)(ObjectFactory.newInstance( 69 factoryClass, ObjectFactory.findClassLoader(), true)); 70 } catch (ClassCastException e4) { 71 throw new DVFactoryException("Schema factory class " + factoryClass + " does not extend from SchemaDVFactory."); 72 } 73 74 } 75 76 protected SchemaDVFactory(){} 78 79 90 public abstract XSSimpleType getBuiltInType(String name); 91 92 98 public abstract SymbolHash getBuiltInTypes(); 99 100 111 public abstract XSSimpleType createTypeRestriction(String name, String targetNamespace, 112 short finalSet, XSSimpleType base, 113 XSObjectList annotations); 114 115 126 public abstract XSSimpleType createTypeList(String name, String targetNamespace, 127 short finalSet, XSSimpleType itemType, 128 XSObjectList annotations); 129 130 141 public abstract XSSimpleType createTypeUnion(String name, String targetNamespace, 142 short finalSet, XSSimpleType[] memberTypes, 143 XSObjectList annotations); 144 145 } 146 | Popular Tags |