Java Doc for CPropertyInfo.java in  » 6.0-JDK-Modules » jaxb-xjc » com » sun » tools » xjc » model » 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 » 6.0 JDK Modules » jaxb xjc » com.sun.tools.xjc.model 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.sun.tools.xjc.model.CPropertyInfo

All known Subclasses:   com.sun.tools.xjc.model.CReferencePropertyInfo,  com.sun.tools.xjc.model.CElementPropertyInfo,  com.sun.tools.xjc.model.CSingleTypePropertyInfo,
CPropertyInfo
abstract public class CPropertyInfo implements PropertyInfo<NType, NClass>,CCustomizable(Code)
Model of a property to be generated.
author:
   Kohsuke Kawaguchi


Field Summary
public  JTypebaseType
     If the base type of the property is overriden, this field is set to non-null.
public  CDefaultValuedefaultValue
     If non-null, keeps the default value in Java representation.
public  booleaninlineBinaryData
     Property with @XmlInlineBinaryData .
public  Stringjavadoc
     Javadoc for this property.
final public  Locatorlocator
    
public  FieldRendererrealization
     Specifies how the field is generated by the backedn.

Constructor Summary
protected  CPropertyInfo(String name, boolean collection, XSComponent source, CCustomizations customizations, Locator locator)
    

Method Summary
abstract public  Vaccept(CPropertyVisitor<V> visitor)
    
public  QNamecollectElementNames(Map<QName, CPropertyInfo> table)
     Puts the element names that this property possesses to the map, so that we can find two properties that own the same element name, which is an error. null if no conflict was found.
public  StringdisplayName()
    
abstract public  CAdaptergetAdapter()
    
public  CCustomizationsgetCustomizations()
    
public  LocatorgetLocator()
    
public  StringgetName()
     Name of the property.

This method is implemented to follow the contract of PropertyInfo.getName , and therefore it always returns the name of the annotated field.

This name is normally not useful for the rest of XJC, which usually wants to access the "public name" of the property. A "public name" of the property is a name like "FooBar" which is used as a seed for generating the accessor methods. This is the name controlled by the schema customization via users.

If the caller is calling this method statically, it's usually the sign of a mistake.

public  StringgetName(boolean isPublic)
     Gets the name of the property.
Parameters:
  isPublic - if true, this method returns a name like "FooBar", whichshould be used as a seed for generating user-visible names(such as accessors like "getFooBar".)

if false, this method returns the "name of the property"as defined in the j2s side of the spec.

final public  XSComponentgetSchemaComponent()
     If this model object is built from XML Schema, this property returns a schema component from which the model is built.
final public  booleanhasAnnotation(Class<? extends Annotation> annotationType)
    
public  booleaninlineBinaryData()
    
public  booleanisCollection()
    
public  booleanisOptionalPrimitive()
     Returns true if this property needs to represent null just for the purpose of representing an absence of the property.
public  booleanisUnboxable()
     Returns true if this property is "unboxable".

In general, a property often has to be capable of representing null to indicate the absence of the value.

protected static  booleanneedsExplicitTypeName(TypeUse type, QName typeName)
     Checks if the given TypeUse would need an explicit XmlSchemaType annotation with the given type name.
public  CTypeInfoparent()
    
final public  AreadAnnotation(Class<A> annotationType)
    
abstract public  Collection<? extends CTypeInfo>ref()
    
public  voidsetName(boolean isPublic, String newName)
     Overrides the name of the property.
final  voidsetParent(CClassInfo parent)
    

Field Detail
baseType
public JType baseType(Code)
If the base type of the property is overriden, this field is set to non-null.



defaultValue
public CDefaultValue defaultValue(Code)
If non-null, keeps the default value in Java representation. If CPropertyInfo.isCollection is true, this field is always null, for we don't handle default values for a list.



inlineBinaryData
public boolean inlineBinaryData(Code)
Property with @XmlInlineBinaryData .



javadoc
public String javadoc(Code)
Javadoc for this property. Must not be null.



locator
final public Locator locator(Code)



realization
public FieldRenderer realization(Code)
Specifies how the field is generated by the backedn.




Constructor Detail
CPropertyInfo
protected CPropertyInfo(String name, boolean collection, XSComponent source, CCustomizations customizations, Locator locator)(Code)




Method Detail
accept
abstract public V accept(CPropertyVisitor<V> visitor)(Code)



collectElementNames
public QName collectElementNames(Map<QName, CPropertyInfo> table)(Code)
Puts the element names that this property possesses to the map, so that we can find two properties that own the same element name, which is an error. null if no conflict was found. Otherwise return the QName that has the collision.



displayName
public String displayName()(Code)



getAdapter
abstract public CAdapter getAdapter()(Code)



getCustomizations
public CCustomizations getCustomizations()(Code)



getLocator
public Locator getLocator()(Code)



getName
public String getName()(Code)
Name of the property.

This method is implemented to follow the contract of PropertyInfo.getName , and therefore it always returns the name of the annotated field.

This name is normally not useful for the rest of XJC, which usually wants to access the "public name" of the property. A "public name" of the property is a name like "FooBar" which is used as a seed for generating the accessor methods. This is the name controlled by the schema customization via users.

If the caller is calling this method statically, it's usually the sign of a mistake. Use CPropertyInfo.getName(boolean) method instead, which forces you to think about which name you want to get.
See Also:   CPropertyInfo.getName(boolean)




getName
public String getName(boolean isPublic)(Code)
Gets the name of the property.
Parameters:
  isPublic - if true, this method returns a name like "FooBar", whichshould be used as a seed for generating user-visible names(such as accessors like "getFooBar".)

if false, this method returns the "name of the property"as defined in the j2s side of the spec. This name is usuallysomething like "fooBar", which often corresponds to the XMLelement/attribute name of this property (for taking advantageof annotation defaulting as much as possible)




getSchemaComponent
final public XSComponent getSchemaComponent()(Code)
If this model object is built from XML Schema, this property returns a schema component from which the model is built. null if the model is built from sources other than XML Schema(such as DTD.)



hasAnnotation
final public boolean hasAnnotation(Class<? extends Annotation> annotationType)(Code)



inlineBinaryData
public boolean inlineBinaryData()(Code)



isCollection
public boolean isCollection()(Code)



isOptionalPrimitive
public boolean isOptionalPrimitive()(Code)
Returns true if this property needs to represent null just for the purpose of representing an absence of the property.



isUnboxable
public boolean isUnboxable()(Code)
Returns true if this property is "unboxable".

In general, a property often has to be capable of representing null to indicate the absence of the value. This requires properties to be generated as @XmlElement Float f, not as @XmlElement float f;. But this is slow.

Fortunately, there are cases where we know that the property can never legally be absent. When this condition holds we can generate the optimized "unboxed form".

The exact such conditions depend on the kind of properties, so refer to the implementation code for the details.

This method returns true when the property can be generated as "unboxed form", false otherwise.

When this property is a collection, this method returns true if items in the collection is unboxable. Obviously, the collection itself is always a reference type.




needsExplicitTypeName
protected static boolean needsExplicitTypeName(TypeUse type, QName typeName)(Code)
Checks if the given TypeUse would need an explicit XmlSchemaType annotation with the given type name.



parent
public CTypeInfo parent()(Code)



readAnnotation
final public A readAnnotation(Class<A> annotationType)(Code)



ref
abstract public Collection<? extends CTypeInfo> ref()(Code)



setName
public void setName(boolean isPublic, String newName)(Code)
Overrides the name of the property. This method can be used from Plugin.postProcessModel(ModelErrorHandler) . But the caller should do so with the understanding that this is inherently dangerous method.



setParent
final void setParent(CClassInfo parent)(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

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