private boolean matchesAnnotation(SchemaType annotation) { if (annotation == null) { return false; } if (schemaType == AnyType.getInstance()) { return true; } if (annotation.equals(schemaType)) { return true; } // see if the type annotation is a subtype of the required type int r = config.getTypeHierarchy().schemaTypeRelationship(annotation, schemaType); return r == TypeHierarchy.SAME_TYPE || r == TypeHierarchy.SUBSUMED_BY; }
private boolean matchesAnnotation(SchemaType annotation) { if (annotation == null) { return false; } if (schemaType == AnyType.getInstance()) { return true; } if (annotation.equals(schemaType)) { return true; } // see if the type annotation is a subtype of the required type int r = config.getTypeHierarchy().schemaTypeRelationship(annotation, schemaType); return r == TypeHierarchy.SAME_TYPE || r == TypeHierarchy.SUBSUMED_BY; }
SchemaType s1 = ((NodeTest) t1).getContentType(); SchemaType s2 = ((NodeTest) t2).getContentType(); contentRelationship = schemaTypeRelationship(s1, s2);
SchemaType s1 = ((NodeTest) t1).getContentType(); SchemaType s2 = ((NodeTest) t2).getContentType(); contentRelationship = schemaTypeRelationship(s1, s2);
SchemaType s1 = ((NodeTest)t1).getContentType(); SchemaType s2 = ((NodeTest)t2).getContentType(); contentRelationship = schemaTypeRelationship(s1, s2);
SchemaType s1 = ((NodeTest)t1).getContentType(); SchemaType s2 = ((NodeTest)t2).getContentType(); contentRelationship = schemaTypeRelationship(s1, s2);