com.sun.org.apache.xerces.internal.xs.XSSimpleTypeDefinition Java Examples
The following examples show how to use
com.sun.org.apache.xerces.internal.xs.XSSimpleTypeDefinition.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: XSSimpleTypeDecl.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #2
Source File: XSDHandler.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
private void expandRelatedSimpleTypeComponents(XSSimpleTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { final XSTypeDefinition baseType = type.getBaseType(); if (baseType != null) { addRelatedType(baseType, componentList, namespace, dependencies); } final XSTypeDefinition itemType = type.getItemType(); if (itemType != null) { addRelatedType(itemType, componentList, namespace, dependencies); } final XSTypeDefinition primitiveType = type.getPrimitiveType(); if (primitiveType != null) { addRelatedType(primitiveType, componentList, namespace, dependencies); } final XSObjectList memberTypes = type.getMemberTypes(); if (memberTypes.size() > 0) { for (int i=0; i<memberTypes.size(); i++) { addRelatedType((XSTypeDefinition)memberTypes.item(i), componentList, namespace, dependencies); } } }
Example #3
Source File: XSSimpleTypeDecl.java From hottub with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #4
Source File: XSSimpleTypeDecl.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #5
Source File: XSSimpleTypeDecl.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #6
Source File: XSSimpleTypeDecl.java From JDKSourceCode1.8 with MIT License | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #7
Source File: XSSimpleTypeDecl.java From JDKSourceCode1.8 with MIT License | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #8
Source File: XSSimpleTypeDecl.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #9
Source File: XSSimpleTypeDecl.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #10
Source File: XSSimpleTypeDecl.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #11
Source File: XSSimpleTypeDecl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #12
Source File: XSSimpleTypeDecl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #13
Source File: XSSimpleTypeDecl.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #14
Source File: XSDHandler.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
private void expandRelatedSimpleTypeComponents(XSSimpleTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { final XSTypeDefinition baseType = type.getBaseType(); if (baseType != null) { addRelatedType(baseType, componentList, namespace, dependencies); } final XSTypeDefinition itemType = type.getItemType(); if (itemType != null) { addRelatedType(itemType, componentList, namespace, dependencies); } final XSTypeDefinition primitiveType = type.getPrimitiveType(); if (primitiveType != null) { addRelatedType(primitiveType, componentList, namespace, dependencies); } final XSObjectList memberTypes = type.getMemberTypes(); if (memberTypes.size() > 0) { for (int i=0; i<memberTypes.size(); i++) { addRelatedType((XSTypeDefinition)memberTypes.item(i), componentList, namespace, dependencies); } } }
Example #15
Source File: XSSimpleTypeDecl.java From hottub with GNU General Public License v2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #16
Source File: XSSimpleTypeDecl.java From Bytecoder with Apache License 2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #17
Source File: XSSimpleTypeDecl.java From Bytecoder with Apache License 2.0 | 6 votes |
/** * Checks if a type is derived from another by union. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by union for the reference type */ private boolean isDerivedByUnion (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_UNION) { // get member types XSObjectList memberTypes = ((XSSimpleTypeDefinition)type).getMemberTypes(); for (int i = 0; i < memberTypes.getLength(); i++) { // One of the {member type definitions} is T2. if (memberTypes.item(i) != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName,(XSSimpleTypeDefinition)memberTypes.item(i))) { return true; } } } } return false; }
Example #18
Source File: XSSimpleTypeDecl.java From jdk1.8-source-analysis with Apache License 2.0 | 6 votes |
/** * Checks if a type is derived from another by list. See: * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#TypeInfo-isDerivedFrom * * @param ancestorNS * The namspace of the ancestor type declaration * @param ancestorName * The name of the ancestor type declaration * @param type * The reference type definition * * @return boolean True if the type is derived by list for the reference type */ private boolean isDerivedByList (String ancestorNS, String ancestorName, XSTypeDefinition type) { // If the variety is union if (type !=null && ((XSSimpleTypeDefinition)type).getVariety() == VARIETY_LIST) { // get the {item type} XSTypeDefinition itemType = ((XSSimpleTypeDefinition)type).getItemType(); // T2 is the {item type definition} if (itemType != null) { // T2 is derived from the other type definition by DERIVATION_RESTRICTION if (isDerivedByRestriction(ancestorNS, ancestorName, itemType)) { return true; } } } return false; }
Example #19
Source File: XSDHandler.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
private void expandRelatedSimpleTypeComponents(XSSimpleTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { final XSTypeDefinition baseType = type.getBaseType(); if (baseType != null) { addRelatedType(baseType, componentList, namespace, dependencies); } final XSTypeDefinition itemType = type.getItemType(); if (itemType != null) { addRelatedType(itemType, componentList, namespace, dependencies); } final XSTypeDefinition primitiveType = type.getPrimitiveType(); if (primitiveType != null) { addRelatedType(primitiveType, componentList, namespace, dependencies); } final XSObjectList memberTypes = type.getMemberTypes(); if (memberTypes.size() > 0) { for (int i=0; i<memberTypes.size(); i++) { addRelatedType((XSTypeDefinition)memberTypes.item(i), componentList, namespace, dependencies); } } }
Example #20
Source File: XSSimpleTypeDecl.java From hottub with GNU General Public License v2.0 | 5 votes |
/** * If variety is <code>atomic</code> the primitive type definition (a * built-in primitive datatype definition or the simple ur-type * definition) is available, otherwise <code>null</code>. */ public XSSimpleTypeDefinition getPrimitiveType() { if (fVariety == VARIETY_ATOMIC && fValidationDV != DV_ANYSIMPLETYPE) { XSSimpleTypeDecl pri = this; // recursively get base, until we reach anySimpleType while (pri.fBase != fAnySimpleType) pri = pri.fBase; return pri; } else { // REVISIT: error situation. runtime exception? return null; } }
Example #21
Source File: XSDHandler.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
private void expandRelatedTypeComponents(XSTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { if (type instanceof XSComplexTypeDecl) { expandRelatedComplexTypeComponents((XSComplexTypeDecl) type, componentList, namespace, dependencies); } else if (type instanceof XSSimpleTypeDecl) { expandRelatedSimpleTypeComponents((XSSimpleTypeDefinition) type, componentList, namespace, dependencies); } }
Example #22
Source File: XSDHandler.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
private void expandRelatedTypeComponents(XSTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { if (type instanceof XSComplexTypeDecl) { expandRelatedComplexTypeComponents((XSComplexTypeDecl) type, componentList, namespace, dependencies); } else if (type instanceof XSSimpleTypeDecl) { expandRelatedSimpleTypeComponents((XSSimpleTypeDefinition) type, componentList, namespace, dependencies); } }
Example #23
Source File: XSDHandler.java From jdk1.8-source-analysis with Apache License 2.0 | 5 votes |
private void expandRelatedTypeComponents(XSTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { if (type instanceof XSComplexTypeDecl) { expandRelatedComplexTypeComponents((XSComplexTypeDecl) type, componentList, namespace, dependencies); } else if (type instanceof XSSimpleTypeDecl) { expandRelatedSimpleTypeComponents((XSSimpleTypeDefinition) type, componentList, namespace, dependencies); } }
Example #24
Source File: XSSimpleTypeDecl.java From jdk1.8-source-analysis with Apache License 2.0 | 5 votes |
/** * If variety is <code>list</code> the item type definition (an atomic or * union simple type definition) is available, otherwise * <code>null</code>. */ public XSSimpleTypeDefinition getItemType() { if (fVariety == VARIETY_LIST) { return fItemType; } else { // REVISIT: error situation. runtime exception? return null; } }
Example #25
Source File: XSDHandler.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
private void expandRelatedTypeComponents(XSTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { if (type instanceof XSComplexTypeDecl) { expandRelatedComplexTypeComponents((XSComplexTypeDecl) type, componentList, namespace, dependencies); } else if (type instanceof XSSimpleTypeDecl) { expandRelatedSimpleTypeComponents((XSSimpleTypeDefinition) type, componentList, namespace, dependencies); } }
Example #26
Source File: XSSimpleTypeDecl.java From JDKSourceCode1.8 with MIT License | 5 votes |
/** * If variety is <code>atomic</code> the primitive type definition (a * built-in primitive datatype definition or the simple ur-type * definition) is available, otherwise <code>null</code>. */ public XSSimpleTypeDefinition getPrimitiveType() { if (fVariety == VARIETY_ATOMIC && fValidationDV != DV_ANYSIMPLETYPE) { XSSimpleTypeDecl pri = this; // recursively get base, until we reach anySimpleType while (pri.fBase != fAnySimpleType) pri = pri.fBase; return pri; } else { // REVISIT: error situation. runtime exception? return null; } }
Example #27
Source File: XSSimpleTypeDecl.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * If variety is <code>atomic</code> the primitive type definition (a * built-in primitive datatype definition or the simple ur-type * definition) is available, otherwise <code>null</code>. */ public XSSimpleTypeDefinition getPrimitiveType() { if (fVariety == VARIETY_ATOMIC && fValidationDV != DV_ANYSIMPLETYPE) { XSSimpleTypeDecl pri = this; // recursively get base, until we reach anySimpleType while (pri.fBase != fAnySimpleType) pri = pri.fBase; return pri; } else { // REVISIT: error situation. runtime exception? return null; } }
Example #28
Source File: XSSimpleTypeDecl.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * If variety is <code>list</code> the item type definition (an atomic or * union simple type definition) is available, otherwise * <code>null</code>. */ public XSSimpleTypeDefinition getItemType() { if (fVariety == VARIETY_LIST) { return fItemType; } else { // REVISIT: error situation. runtime exception? return null; } }
Example #29
Source File: XSDHandler.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
private void expandRelatedTypeComponents(XSTypeDefinition type, Vector componentList, String namespace, Map<String, Vector> dependencies) { if (type instanceof XSComplexTypeDecl) { expandRelatedComplexTypeComponents((XSComplexTypeDecl) type, componentList, namespace, dependencies); } else if (type instanceof XSSimpleTypeDecl) { expandRelatedSimpleTypeComponents((XSSimpleTypeDefinition) type, componentList, namespace, dependencies); } }
Example #30
Source File: XSSimpleTypeDecl.java From Bytecoder with Apache License 2.0 | 5 votes |
/** * If variety is <code>atomic</code> the primitive type definition (a * built-in primitive datatype definition or the simple ur-type * definition) is available, otherwise <code>null</code>. */ public XSSimpleTypeDefinition getPrimitiveType() { if (fVariety == VARIETY_ATOMIC && fValidationDV != DV_ANYSIMPLETYPE) { XSSimpleTypeDecl pri = this; // recursively get base, until we reach anySimpleType while (pri.fBase != fAnySimpleType) pri = pri.fBase; return pri; } else { // REVISIT: error situation. runtime exception? return null; } }