1 19 20 package org.netbeans.modules.xml.schema.model.impl; 21 import org.netbeans.modules.xml.schema.model.*; 22 import org.netbeans.modules.xml.xam.dom.NamedComponentReference; 23 import org.netbeans.modules.xml.xam.NamedReferenceable; 24 29 public class SchemaComponentFactoryImpl implements SchemaComponentFactory{ 30 31 private SchemaModelImpl model; 32 33 36 public SchemaComponentFactoryImpl(SchemaModelImpl model) { 37 this.model = model; 38 } 39 40 47 public SchemaComponent create(org.w3c.dom.Element currentElement, SchemaComponent parent) { 48 SchemaElementNodeVisitor v = new SchemaElementNodeVisitor(); 49 return v.createSubComponent(parent,currentElement,model); 50 } 51 52 public Whitespace createWhitespace() { 53 return new WhitespaceImpl(model); 54 } 55 56 public Unique createUnique() { 57 return new UniqueImpl(model); 58 } 59 60 public Union createUnion() { 61 return new UnionImpl(model); 62 } 63 64 public TotalDigits createTotalDigits() { 65 return new TotalDigitsImpl(model); 66 } 67 68 public GroupReference createGroupReference() { 69 return new GroupReferenceImpl(model); 70 } 71 72 public GlobalGroup createGroupDefinition() { 73 return new GlobalGroupImpl(model); 74 } 75 76 public GlobalSimpleType createGlobalSimpleType() { 77 return new GlobalSimpleTypeImpl(model); 78 } 79 80 public GlobalElement createGlobalElement() { 81 return new GlobalElementImpl(model); 82 } 83 84 public GlobalComplexType createGlobalComplexType() { 85 return new GlobalComplexTypeImpl(model); 86 } 87 88 public GlobalAttributeGroup createGlobalAttributeGroup() { 89 return new GlobalAttributeGroupImpl(model); 90 } 91 92 public GlobalAttribute createGlobalAttribute() { 93 return new GlobalAttributeImpl(model); 94 } 95 96 public FractionDigits createFractionDigits() { 97 return new FractionDigitsImpl(model); 98 } 99 100 public Field createField() { 101 return new FieldImpl(model); 102 } 103 104 public All createAll() { 105 return new AllImpl(model); 106 } 107 108 public Annotation createAnnotation() { 109 return new AnnotationImpl(model); 110 } 111 112 public AnyElement createAny() { 113 return new AnyImpl(model); 114 } 115 116 public AnyAttribute createAnyAttribute() { 117 return new AnyAttributeImpl(model); 118 } 119 120 public AttributeGroupReference createAttributeGroupReference() { 121 return new AttributeGroupReferenceImpl(model); 122 } 123 124 public Choice createChoice() { 125 return new ChoiceImpl(model); 126 } 127 128 public ComplexContent createComplexContent() { 129 return new ComplexContentImpl(model); 130 } 131 132 public ComplexContentRestriction createComplexContentRestriction() { 133 return new ComplexContentRestrictionImpl(model); 134 } 135 136 public ComplexExtension createComplexExtension() { 137 return new ComplexExtensionImpl(model); 138 } 139 140 public Documentation createDocumentation() { 141 return new DocumentationImpl(model); 142 } 143 144 public Enumeration createEnumeration() { 145 return new EnumerationImpl(model); 146 } 147 148 public Import createImport() { 149 return new ImportImpl(model); 150 } 151 152 public Include createInclude() { 153 return new IncludeImpl(model); 154 } 155 156 public Key createKey() { 157 return new KeyImpl(model); 158 } 159 160 public KeyRef createKeyRef() { 161 return new KeyRefImpl(model); 162 } 163 164 public Length createLength() { 165 return new LengthImpl(model); 166 } 167 168 public List createList() { 169 return new ListImpl(model); 170 } 171 172 public LocalAttribute createLocalAttribute() { 173 return new LocalAttributeImpl(model); 174 } 175 176 public LocalComplexType createLocalComplexType() { 177 return new LocalComplexTypeImpl(model); 178 } 179 180 public LocalElement createLocalElement() { 181 return new LocalElementImpl(model); 182 } 183 184 public LocalSimpleType createLocalSimpleType() { 185 return new LocalSimpleTypeImpl(model); 186 } 187 188 public MaxExclusive createMaxExclusive() { 189 return new MaxExclusiveImpl(model); 190 } 191 192 public MaxInclusive createMaxInclusive() { 193 return new MaxInclusiveImpl(model); 194 } 195 196 public MaxLength createMaxLength() { 197 return new MaxLengthImpl(model); 198 } 199 200 public MinExclusive createMinExclusive() { 201 return new MinExclusiveImpl(model); 202 } 203 204 public MinInclusive createMinInclusive() { 205 return new MinInclusiveImpl(model); 206 } 207 208 public MinLength createMinLength() { 209 return new MinLengthImpl(model); 210 } 211 212 public Pattern createPattern() { 213 return new PatternImpl(model); 214 } 215 216 public Redefine createRedefine() { 217 return new RedefineImpl(model); 218 } 219 220 public Schema createSchema() { 221 return new SchemaImpl(model); 222 } 223 224 public Selector createSelector() { 225 return new SelectorImpl(model); 226 } 227 228 public Sequence createSequence() { 229 return new SequenceImpl(model); 230 } 231 232 public SimpleContent createSimpleContent() { 233 return new SimpleContentImpl(model); 234 } 235 236 public SimpleContentRestriction createSimpleContentRestriction() { 237 return new SimpleContentRestrictionImpl(model); 238 } 239 240 public SimpleExtension createSimpleExtension() { 241 return new SimpleExtensionImpl(model); 242 } 243 244 public SimpleTypeRestriction createSimpleTypeRestriction() { 245 return new SimpleTypeRestrictionImpl(model); 246 } 247 248 public <T extends ReferenceableSchemaComponent> NamedComponentReference<T> createGlobalReference( 249 T type, Class <T> c, SchemaComponent parent){ 250 return new GlobalReferenceImpl<T>(type, c, (SchemaComponentImpl) parent); 251 } 252 253 public Notation createNotation() { 254 return new NotationImpl(model); 255 } 256 257 public AppInfo createAppInfo() { 258 return new AppInfoImpl(model); 259 } 260 261 public ElementReference createElementReference() { 262 return new ElementReferenceImpl(model); 263 } 264 265 public AttributeReference createAttributeReference() { 266 return new AttributeReferenceImpl(model); 267 } 268 269 } 270 | Popular Tags |