public void attGroupDecl(XSAttGroupDecl decl) { if(check(decl)) attContainer(decl); }
/** * Checks unused customizations on this component * and returns true if this is the first time this * component is checked. */ private boolean check( XSComponent c ) { if( !visitedComponents.add(c) ) return false; // already processed for( BIDeclaration decl : builder.getBindInfo(c).getDecls() ) check(decl, c); checkExpectedContentTypes(c); return true; }
/** * Runs the check. */ void run() { for( XSSchema s : Ring.get(XSSchemaSet.class).getSchemas() ) { schema(s); run( s.getAttGroupDecls() ); run( s.getAttributeDecls() ); run( s.getComplexTypes() ); run( s.getElementDecls() ); run( s.getModelGroupDecls() ); run( s.getNotations() ); run( s.getSimpleTypes() ); } }
public void notation(XSNotation notation) { check(notation); }
private void check(BIDeclaration decl, XSComponent c) { if( !decl.isAcknowledged() ) { getErrorReporter().error( decl.getLocation(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION, decl.getName().getLocalPart() ); getErrorReporter().error( c.getLocator(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION_LOCATION); // mark it as acknowledged to avoid // duplicated error messages. decl.markAsAcknowledged(); } for (BIDeclaration d : decl.getChildren()) check(d,c); }
private void _build() { // do the binding buildContents(); getClassSelector().executeTasks(); // additional error check // Reports unused customizations to the user as errors. Ring.get(UnusedCustomizationChecker.class).run(); Ring.get(ModelChecker.class).check(); }
private void checkExpectedContentTypes(XSComponent c) { if(c.getForeignAttribute(WellKnownNamespace.XML_MIME_URI, Const.EXPECTED_CONTENT_TYPES)==null) return; // no such attribute if(c instanceof XSParticle) return; // particles get the same foreign attributes as local element decls, // so we need to skip them if(!stb.isAcknowledgedXmimeContentTypes(c)) { // this is not used getErrorReporter().warning(c.getLocator(),Messages.WARN_UNUSED_EXPECTED_CONTENT_TYPES); } }
public void wildcard(XSWildcard wc) { check(wc); }
private void check(BIDeclaration decl, XSComponent c) { if( !decl.isAcknowledged() ) { getErrorReporter().error( decl.getLocation(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION, decl.getName().getLocalPart() ); getErrorReporter().error( c.getLocator(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION_LOCATION); // mark it as acknowledged to avoid // duplicated error messages. decl.markAsAcknowledged(); } for (BIDeclaration d : decl.getChildren()) check(d,c); }
private void _build() { // do the binding buildContents(); getClassSelector().executeTasks(); // additional error check // Reports unused customizations to the user as errors. Ring.get(UnusedCustomizationChecker.class).run(); Ring.get(ModelChecker.class).check(); for( Plugin ma : activePlugins ) ma.postProcessModel(model, Ring.get(ErrorReceiver.class)); }
private void checkExpectedContentTypes(XSComponent c) { if(c.getForeignAttribute(WellKnownNamespace.XML_MIME_URI, Const.EXPECTED_CONTENT_TYPES)==null) return; // no such attribute if(c instanceof XSParticle) return; // particles get the same foreign attributes as local element decls, // so we need to skip them if(!stb.isAcknowledgedXmimeContentTypes(c)) { // this is not used getErrorReporter().warning(c.getLocator(),Messages.WARN_UNUSED_EXPECTED_CONTENT_TYPES); } }
public void xpath(XSXPath xp) { check(xp); }
public void attGroupDecl(XSAttGroupDecl decl) { if(check(decl)) attContainer(decl); }
/** * Checks unused customizations on this component * and returns true if this is the first time this * component is checked. */ private boolean check( XSComponent c ) { if( !visitedComponents.add(c) ) return false; // already processed for( BIDeclaration decl : builder.getBindInfo(c).getDecls() ) check(decl, c); checkExpectedContentTypes(c); return true; }
/** * Runs the check. */ void run() { for( XSSchema s : Ring.get(XSSchemaSet.class).getSchemas() ) { schema(s); run( s.getAttGroupDecls() ); run( s.getAttributeDecls() ); run( s.getComplexTypes() ); run( s.getElementDecls() ); run( s.getModelGroupDecls() ); run( s.getNotations() ); run( s.getSimpleTypes() ); } }
private void check(BIDeclaration decl, XSComponent c) { if( !decl.isAcknowledged() ) { getErrorReporter().error( decl.getLocation(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION, decl.getName().getLocalPart() ); getErrorReporter().error( c.getLocator(), Messages.ERR_UNACKNOWLEDGED_CUSTOMIZATION_LOCATION); // mark it as acknowledged to avoid // duplicated error messages. decl.markAsAcknowledged(); } for (BIDeclaration d : decl.getChildren()) check(d,c); }
private void _build() { // do the binding buildContents(); getClassSelector().executeTasks(); // additional error check // Reports unused customizations to the user as errors. Ring.get(UnusedCustomizationChecker.class).run(); Ring.get(ModelChecker.class).check(); for( Plugin ma : activePlugins ) ma.postProcessModel(model, Ring.get(ErrorReceiver.class)); }
private void checkExpectedContentTypes(XSComponent c) { if(c.getForeignAttribute(WellKnownNamespace.XML_MIME_URI, Const.EXPECTED_CONTENT_TYPES)==null) return; // no such attribute if(c instanceof XSParticle) return; // particles get the same foreign attributes as local element decls, // so we need to skip them if(!stb.isAcknowledgedXmimeContentTypes(c)) { // this is not used getErrorReporter().warning(c.getLocator(),Messages.WARN_UNUSED_EXPECTED_CONTENT_TYPES); } }
public void empty(XSContentType empty) { check(empty); }
public void attGroupDecl(XSAttGroupDecl decl) { if(check(decl)) attContainer(decl); }