public void onEndChild( XSDatatypeExp type ) { // handle redefinition of simpleType. final XMLSchemaReader reader = (XMLSchemaReader)this.reader; final String typeName = type.name; if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } oldSimpleTypeExp.set(type); reader.setDeclaredLocationOf(oldSimpleTypeExp); // restore the association reader.currentSchema.simpleTypes.redefine( oldSimpleTypeExp.name, oldSimpleTypeExp ); oldSimpleTypeExp = null; }
public void onEndChild( XSDatatypeExp type ) { // handle redefinition of simpleType. final XMLSchemaReader reader = (XMLSchemaReader)this.reader; final String typeName = type.name; if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } oldSimpleTypeExp.set(type); reader.setDeclaredLocationOf(oldSimpleTypeExp); // restore the association reader.currentSchema.simpleTypes.redefine( oldSimpleTypeExp.name, oldSimpleTypeExp ); oldSimpleTypeExp = null; }
public void onEndChild( XSDatatypeExp type ) { // handle redefinition of simpleType. final XMLSchemaReader reader = (XMLSchemaReader)this.reader; final String typeName = type.name; if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } oldSimpleTypeExp.set(type); reader.setDeclaredLocationOf(oldSimpleTypeExp); // restore the association reader.currentSchema.simpleTypes.redefine( oldSimpleTypeExp.name, oldSimpleTypeExp ); oldSimpleTypeExp = null; }
public void onEndChild( XSDatatypeExp type ) { // handle redefinition of simpleType. final XMLSchemaReader reader = (XMLSchemaReader)this.reader; final String typeName = type.name; if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } oldSimpleTypeExp.set(type); reader.setDeclaredLocationOf(oldSimpleTypeExp); // restore the association reader.currentSchema.simpleTypes.redefine( oldSimpleTypeExp.name, oldSimpleTypeExp ); oldSimpleTypeExp = null; }
reader.setDeclaredLocationOf(decl); reader.setDeclaredLocationOf(decl.body); return decl;
reader.setDeclaredLocationOf(decl); reader.setDeclaredLocationOf(decl.body); return decl;
reader.setDeclaredLocationOf(decl); reader.setDeclaredLocationOf(decl.body); return decl;
reader.setDeclaredLocationOf(decl); reader.setDeclaredLocationOf(decl.body); return decl;
protected Expression annealExpression(Expression contentType) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; if( !isGlobal() ) return contentType; // if this is a global declaration register it. String name = startTag.getAttribute("name"); if( name==null ) { reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "attributeGroup", "name" ); return Expression.epsilon; // recover by returning something meaningless. // the parent state will ignore this. } AttributeGroupExp exp; if( isRedefine() ) exp = (AttributeGroupExp)super.oldDecl; else { exp = reader.currentSchema.attributeGroups.getOrCreate(name); if( exp.exp!=null ) reader.reportError( new Locator[]{this.location,reader.getDeclaredLocationOf(exp)}, XMLSchemaReader.ERR_DUPLICATE_ATTRIBUTE_GROUP_DEFINITION, new Object[]{name} ); } reader.setDeclaredLocationOf(exp); exp.exp = contentType; exp.wildcard = this.wildcard; return exp; } }
protected Expression annealExpression(Expression contentType) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; if( !isGlobal() ) return contentType; // if this is a global declaration register it. String name = startTag.getAttribute("name"); if( name==null ) { reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "attributeGroup", "name" ); return Expression.epsilon; // recover by returning something meaningless. // the parent state will ignore this. } AttributeGroupExp exp; if( isRedefine() ) exp = (AttributeGroupExp)super.oldDecl; else { exp = reader.currentSchema.attributeGroups.getOrCreate(name); if( exp.exp!=null ) reader.reportError( new Locator[]{this.location,reader.getDeclaredLocationOf(exp)}, XMLSchemaReader.ERR_DUPLICATE_ATTRIBUTE_GROUP_DEFINITION, new Object[]{name} ); } reader.setDeclaredLocationOf(exp); exp.exp = contentType; exp.wildcard = this.wildcard; return exp; } }
protected Expression annealExpression(Expression contentType) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; if( !isGlobal() ) return contentType; // if this is a global declaration register it. String name = startTag.getAttribute("name"); if( name==null ) { reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "attributeGroup", "name" ); return Expression.epsilon; // recover by returning something meaningless. // the parent state will ignore this. } AttributeGroupExp exp; if( isRedefine() ) exp = (AttributeGroupExp)super.oldDecl; else { exp = reader.currentSchema.attributeGroups.getOrCreate(name); if( exp.exp!=null ) reader.reportError( new Locator[]{this.location,reader.getDeclaredLocationOf(exp)}, XMLSchemaReader.ERR_DUPLICATE_ATTRIBUTE_GROUP_DEFINITION, new Object[]{name} ); } reader.setDeclaredLocationOf(exp); exp.exp = contentType; exp.wildcard = this.wildcard; return exp; } }
public void onEndChild( XSDatatypeExp type ) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; // final XSDatatypeImpl dti = (XSDatatypeImpl)type; // final String typeName = dti.getName(); String typeName = reader.getCurrentState().getStartTag().getAttribute("name"); if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } // memorize this type. final SimpleTypeExp exp = reader.currentSchema.simpleTypes.getOrCreate(typeName); if(exp.getType()!=null ) { reader.reportError( XMLSchemaReader.ERR_DATATYPE_ALREADY_DEFINED, typeName ); return; // recover by ignoring this declaration } exp.set(type); reader.setDeclaredLocationOf(exp); } }
public void onEndChild( XSDatatypeExp type ) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; // final XSDatatypeImpl dti = (XSDatatypeImpl)type; // final String typeName = dti.getName(); String typeName = reader.getCurrentState().getStartTag().getAttribute("name"); if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } // memorize this type. final SimpleTypeExp exp = reader.currentSchema.simpleTypes.getOrCreate(typeName); if(exp.getType()!=null ) { reader.reportError( XMLSchemaReader.ERR_DATATYPE_ALREADY_DEFINED, typeName ); return; // recover by ignoring this declaration } exp.set(type); reader.setDeclaredLocationOf(exp); } }
public void onEndChild( XSDatatypeExp type ) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; // final XSDatatypeImpl dti = (XSDatatypeImpl)type; // final String typeName = dti.getName(); String typeName = reader.getCurrentState().getStartTag().getAttribute("name"); if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } // memorize this type. final SimpleTypeExp exp = reader.currentSchema.simpleTypes.getOrCreate(typeName); if(exp.getType()!=null ) { reader.reportError( XMLSchemaReader.ERR_DATATYPE_ALREADY_DEFINED, typeName ); return; // recover by ignoring this declaration } exp.set(type); reader.setDeclaredLocationOf(exp); } }
protected Expression annealExpression(Expression contentType) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; if( !isGlobal() ) return contentType; // if this is a global declaration register it. String name = startTag.getAttribute("name"); if( name==null ) { reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "attributeGroup", "name" ); return Expression.epsilon; // recover by returning something meaningless. // the parent state will ignore this. } AttributeGroupExp exp; if( isRedefine() ) exp = (AttributeGroupExp)super.oldDecl; else { exp = reader.currentSchema.attributeGroups.getOrCreate(name); if( exp.exp!=null ) reader.reportError( new Locator[]{this.location,reader.getDeclaredLocationOf(exp)}, XMLSchemaReader.ERR_DUPLICATE_ATTRIBUTE_GROUP_DEFINITION, new Object[]{name} ); } reader.setDeclaredLocationOf(exp); exp.exp = contentType; exp.wildcard = this.wildcard; return exp; } }
public void onEndChild( XSDatatypeExp type ) { final XMLSchemaReader reader = (XMLSchemaReader)this.reader; // final XSDatatypeImpl dti = (XSDatatypeImpl)type; // final String typeName = dti.getName(); String typeName = reader.getCurrentState().getStartTag().getAttribute("name"); if( typeName==null ) { // top-level simpleType must define a named type reader.reportError( XMLSchemaReader.ERR_MISSING_ATTRIBUTE, "simpleType", "name" ); return; // recover by ignoring this declaration } // memorize this type. final SimpleTypeExp exp = reader.currentSchema.simpleTypes.getOrCreate(typeName); if(exp.getType()!=null ) { reader.reportError( XMLSchemaReader.ERR_DATATYPE_ALREADY_DEFINED, typeName ); return; // recover by ignoring this declaration } exp.set(type); reader.setDeclaredLocationOf(exp); } }
new Object[]{name} ); reader.setDeclaredLocationOf(decl); decl.exp = contentType;
new Object[]{name} ); reader.setDeclaredLocationOf(decl); decl.exp = contentType;
new Object[]{name} ); reader.setDeclaredLocationOf(decl); decl.exp = contentType;
new Object[]{name} ); reader.setDeclaredLocationOf(decl); decl.exp = contentType;