Java Doc for SchemaType.java in  » XML » XPath-Saxon » net » sf » saxon » type » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » XML » XPath Saxon » net.sf.saxon.type 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


net.sf.saxon.type.SchemaType

SchemaType
public interface SchemaType extends SchemaComponent(Code)
SchemaType is an interface implemented by all schema types: simple and complex types, built-in and user-defined types.

There is a hierarchy of interfaces that extend SchemaType, representing the top levels of the schema type system: SimpleType and ComplexType, with SimpleType further subdivided into List, Union, and Atomic types.

The implementations of these interfaces are organized into a different hierarchy: on the one side, built-in types such as AnyType, AnySimpleType, and the built-in atomic types and list types; on the other side, user-defined types defined in a schema.



Field Summary
final public static  intDERIVATION_EXTENSION
     If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the derivation by extension.
final public static  intDERIVATION_LIST
     If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the list.
The reference type definition is derived by list from the other type definition if there exists two type definitions T1 and T2 such as the reference type definition is derived from T1 by DERIVATION_RESTRICTION or DERIVATION_EXTENSION, T2 is derived from the other type definition by DERIVATION_RESTRICTION, T1 has {variety} list, and T2 is the {item type definition}.
final public static  intDERIVATION_RESTRICTION
     If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the derivation by restriction if complex types are involved, or a restriction if simple types are involved.
final public static  intDERIVATION_UNION
     If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the union if simple types are involved.
The reference type definition is derived by union from the other type definition if there exists two type definitions T1 and T2 such as the reference type definition is derived from T1 by DERIVATION_RESTRICTION or DERIVATION_EXTENSION, T2 is derived from the other type definition by DERIVATION_RESTRICTION, T1 has {variety} union, and one of the {member type definitions} is T2.
final public static  intDERIVE_BY_SUBSTITUTION
     Derivation by substitution.


Method Summary
 booleanallowsDerivation(int derivation)
    
 voidanalyzeContentExpression(Expression expression, int kind, StaticContext env)
     Analyze an expression to see whether the expression is capable of delivering a value of this type.
 Valueatomize(NodeInfo node)
     Get the typed value of a node that is annotated with this schema type.
 SchemaTypegetBaseType()
     Returns the base type that this type inherits from.
 intgetBlock()
    
 intgetDerivationMethod()
     Gets the integer code of the derivation method used to derive this type from its parent.
 StringgetDescription()
     Get a description of this type for use in error messages.
 StringgetDisplayName()
    
 intgetFingerprint()
     Get the fingerprint of the name of this type the fingerprint.
 intgetNameCode()
     Get the namecode of the name of this type.
 SequenceIteratorgetTypedValue(NodeInfo node)
     Get the typed value of a node that is annotated with this schema type.
 booleanisComplexType()
    
 booleanisSameType(SchemaType other)
     Test whether this is the same type as another type.
 booleanisSimpleType()
    
public  voidisTypeDerivationOK(SchemaType base, int block)
     Check that this type is validly derived from a given type, following the rules for the Schema Component Constraint "Is Type Derivation OK (Simple)" (3.14.6) or "Is Type Derivation OK (Complex)" (3.4.6) as appropriate.

Field Detail
DERIVATION_EXTENSION
final public static int DERIVATION_EXTENSION(Code)
If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the derivation by extension.
The reference type definition is derived by extension from the other type definition if the other type definition can be reached recursively following the {base type definition} property from the reference type definition, and at least one of the derivation methods involved is an extension.



DERIVATION_LIST
final public static int DERIVATION_LIST(Code)
If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the list.
The reference type definition is derived by list from the other type definition if there exists two type definitions T1 and T2 such as the reference type definition is derived from T1 by DERIVATION_RESTRICTION or DERIVATION_EXTENSION, T2 is derived from the other type definition by DERIVATION_RESTRICTION, T1 has {variety} list, and T2 is the {item type definition}. Note that T1 could be the same as the reference type definition, and T2 could be the same as the other type definition.



DERIVATION_RESTRICTION
final public static int DERIVATION_RESTRICTION(Code)
If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the derivation by restriction if complex types are involved, or a restriction if simple types are involved.
The reference type definition is derived by restriction from the other type definition if the other type definition is the same as the reference type definition, or if the other type definition can be reached recursively following the {base type definition} property from the reference type definition, and all the derivation methods involved are restriction.



DERIVATION_UNION
final public static int DERIVATION_UNION(Code)
If the document's schema is an XML Schema [XML Schema Part 1] , this constant represents the union if simple types are involved.
The reference type definition is derived by union from the other type definition if there exists two type definitions T1 and T2 such as the reference type definition is derived from T1 by DERIVATION_RESTRICTION or DERIVATION_EXTENSION, T2 is derived from the other type definition by DERIVATION_RESTRICTION, T1 has {variety} union, and one of the {member type definitions} is T2. Note that T1 could be the same as the reference type definition, and T2 could be the same as the other type definition.



DERIVE_BY_SUBSTITUTION
final public static int DERIVE_BY_SUBSTITUTION(Code)
Derivation by substitution. This constant, unlike the others, is NOT defined in the DOM level 3 TypeInfo interface.





Method Detail
allowsDerivation
boolean allowsDerivation(int derivation)(Code)
Determines whether derivation (of a particular kind) from this type is allowed, based on the "final" property
Parameters:
  derivation - the kind of derivation, for example SchemaType.DERIVATION_LIST true if this kind of derivation is allowed



analyzeContentExpression
void analyzeContentExpression(Expression expression, int kind, StaticContext env) throws XPathException(Code)
Analyze an expression to see whether the expression is capable of delivering a value of this type.
Parameters:
  expression - the expression that delivers the content
Parameters:
  kind - the node kind whose content is being delivered: Type.ELEMENT,Type.ATTRIBUTE, or Type.DOCUMENT
Parameters:
  env - The static evaluation context for the query or stylesheet
throws:
  XPathException - if the expression will never deliver a value of the correct type



atomize
Value atomize(NodeInfo node) throws XPathException(Code)
Get the typed value of a node that is annotated with this schema type. The result of this method will always be consistent with the method SchemaType.getTypedValue . However, this method is often more convenient and may be more efficient, especially in the common case where the value is expected to be a singleton.
Parameters:
  node - the node whose typed value is required the typed value.
since:
   8.5



getBaseType
SchemaType getBaseType() throws UnresolvedReferenceException(Code)
Returns the base type that this type inherits from. This method can be used to get the base type of a type that is known to be valid. If this type is a Simpletype that is a built in primitive type then null is returned. the base type.
throws:
  IllegalStateException - if this type is not valid.



getBlock
int getBlock()(Code)
Returns the value of the 'block' attribute for this type, as a bit-signnificant integer with fields such as SchemaType.DERIVATION_LIST and SchemaType.DERIVATION_EXTENSION the value of the 'block' attribute for this type



getDerivationMethod
int getDerivationMethod()(Code)
Gets the integer code of the derivation method used to derive this type from its parent. Returns zero for primitive types. a numeric code representing the derivation method, for example SchemaType.DERIVATION_RESTRICTION



getDescription
String getDescription()(Code)
Get a description of this type for use in error messages. This is the same as the display name in the case of named types; for anonymous types it identifies the type by its position in a source schema document. text identifing the type, for use in a phrase such as "the type XXXX".



getDisplayName
String getDisplayName()(Code)
Get the display name of the type: that is, a lexical QName with an arbitrary prefix a lexical QName identifying the type



getFingerprint
int getFingerprint()(Code)
Get the fingerprint of the name of this type the fingerprint. Returns an invented fingerprint for an anonymous type.



getNameCode
int getNameCode()(Code)
Get the namecode of the name of this type. This includes the prefix from the original type declaration: in the case of built-in types, there may be a conventional prefix or there may be no prefix.



getTypedValue
SequenceIterator getTypedValue(NodeInfo node) throws XPathException(Code)
Get the typed value of a node that is annotated with this schema type. The results of this method are consistent with the SchemaType.atomize method, but this version returns a SequenceIterator which may be more efficient when handling long lists.
Parameters:
  node - the node whose typed value is required a SequenceIterator over the atomic values making up the typed value of the specifiednode. The objects returned by this iterator are of type net.sf.saxon.value.AtomicValue



isComplexType
boolean isComplexType()(Code)
Test whether this SchemaType is a complex type true if this SchemaType is a complex type



isSameType
boolean isSameType(SchemaType other)(Code)
Test whether this is the same type as another type. They are considered to be the same type if they are derived from the same type definition in the original XML representation (which can happen when there are multiple includes of the same file)



isSimpleType
boolean isSimpleType()(Code)
Test whether this SchemaType is a simple type true if this SchemaType is a simple type



isTypeDerivationOK
public void isTypeDerivationOK(SchemaType base, int block) throws SchemaException, ValidationException(Code)
Check that this type is validly derived from a given type, following the rules for the Schema Component Constraint "Is Type Derivation OK (Simple)" (3.14.6) or "Is Type Derivation OK (Complex)" (3.4.6) as appropriate.
Parameters:
  base - the base type; the algorithm tests whether derivation from this type is permitted
Parameters:
  block - the derivations that are blocked by the relevant element declaration
throws:
  SchemaException - if the derivation is not allowed



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.