Java Doc for BindingGenerator.java in  » XML » jibx-1.1.5 » org » jibx » binding » generator » 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 » jibx 1.1.5 » org.jibx.binding.generator 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jibx.binding.generator.BindingGenerator

BindingGenerator
public class BindingGenerator (Code)
Binding generator implementation.

Inner Class :public static class MappingDetail


Constructor Summary
public  BindingGenerator(GlobalCustom glob)
     Create a generator based on a particular set of customizations.

Method Summary
public  booleancheckInclude(String type)
     Check if a class needs to be included in the binding.
public  BindingHolderconfigureBindings(String name)
     Configure the names to be used for writing bindings to files.
public  voiddefineCollection(String itype, String iname, CollectionElement coll, BindingHolder hold)
     Define the details of a collection binding.
public  voidexpandReferences(String type, ReferenceCountMap refmap)
     Expand all references from a class.
public  BindingHolderfindBinding(String uri)
     Find the binding to be used for a particular namespace.
public  voidgenerate(Boolean abstr, List classes)
     Generate binding(s) for a list of classes.
public  voidgenerateSpecified(ArrayList qnames, List concrs, List abstrs)
     Generate binding(s) for lists of classes.
public  BindingHoldergetBinding(String uri)
     Get the binding definition for a namespace.
public  MappingDetailgetMappingDetail(String type)
     Get the mapping details for a class.
public  ArrayListgetNamespaces()
     Get the list of binding namespace URIs.
public static  booleanisEqual(Object a, Object b)
     General object comparison method.
public  booleanisValueClass(String type)
     Check if a class represents a simple value.
public static  voidmain(String[] args)
     Run the binding generation using command line parameters.
public  voidwriteBindings(File dir)
     Write the bindings to supplied destination path.


Constructor Detail
BindingGenerator
public BindingGenerator(GlobalCustom glob)(Code)
Create a generator based on a particular set of customizations.
Parameters:
  glob -




Method Detail
checkInclude
public boolean checkInclude(String type)(Code)
Check if a class needs to be included in the binding. This checks all members of the class and if necessary superclasses, returning true if any member is ultimately found with a simple value.
Parameters:
  type - fully qualified class name true if class to be included in binding,false if it should be skipped



configureBindings
public BindingHolder configureBindings(String name)(Code)
Configure the names to be used for writing bindings to files. If only one binding has been defined, it just gets the supplied name. If multiple bindings have been defined, a single root binding is constructed which includes all the other bindings, and that root binding is given the supplied names while the other bindings are given unique names within the same directory.
Parameters:
  name - file name for root or singleton binding definition root or singleton binding holder



defineCollection
public void defineCollection(String itype, String iname, CollectionElement coll, BindingHolder hold)(Code)
Define the details of a collection binding. Collection bindings may be empty (in the case where the item type is directly mapped), have a <value> child element, or have either a mapping reference or direct definition <structure> child element. This determines the appropriate form based on the item type.
Parameters:
  itype -
Parameters:
  iname -
Parameters:
  coll -
Parameters:
  hold -



expandReferences
public void expandReferences(String type, ReferenceCountMap refmap)(Code)
Expand all references from a class. This checks the types of all members of the class, counting references and calling itself recursively for any types which are not primitives and not java.* or javax.* classes. It also expands the superclass, if specified by the class customizations.
Parameters:
  type - fully qualified class name
Parameters:
  refmap - reference count map



findBinding
public BindingHolder findBinding(String uri)(Code)
Find the binding to be used for a particular namespace. If this is the first time a particular namespace was requested, a new binding will be created for that namespace and returned.
Parameters:
  uri - namespace URI (null if no namespace) binding holder



generate
public void generate(Boolean abstr, List classes)(Code)
Generate binding(s) for a list of classes. This creates a <mapping> definition for each class in the list, and either embeds <structure> definitions or creates separate <mapping>s for other classes referenced by these classes. If all the classes use the same namespace only the binding for that namespace will be created; otherwise, a separate binding will be created for each namespace.
Parameters:
  abstr - force abstract mapping flag (determined by classcustomizations if null)
Parameters:
  classes - class list



generateSpecified
public void generateSpecified(ArrayList qnames, List concrs, List abstrs)(Code)
Generate binding(s) for lists of classes. This creates a <mapping> definition for each class in the lists, and either embeds <structure> definitions or creates separate <mapping>s for other classes referenced by these classes. If all the classes use the same namespace only the binding for that namespace will be created; otherwise, a separate binding will be created for each namespace.
Parameters:
  qnames - list of names for concrete mappings
Parameters:
  concrs - list of classes to be given concrete mappings
Parameters:
  abstrs - list of classes to be given abstract mappings



getBinding
public BindingHolder getBinding(String uri)(Code)
Get the binding definition for a namespace. This method should only be used after the BindingGenerator.generate(boolean,ArrayList) method has been called.
Parameters:
  uri - binding holder, or null if none



getMappingDetail
public MappingDetail getMappingDetail(String type)(Code)
Get the mapping details for a class. This method should only be used after the BindingGenerator.generate(boolean,ArrayList) method has been called.
Parameters:
  type - fully-qualified class name mapping details, or null if none



getNamespaces
public ArrayList getNamespaces()(Code)
Get the list of binding namespace URIs. namespaces



isEqual
public static boolean isEqual(Object a, Object b)(Code)
General object comparison method. Don't know why Sun hasn't seen fit to include this somewhere, but at least it's easy to write (over and over again).
Parameters:
  a - first object to be compared
Parameters:
  b - second object to be compared true if both objects are null, or ifa.equals(b); false otherwise



isValueClass
public boolean isValueClass(String type)(Code)
Check if a class represents a simple value. TODO: implement ClassCustom hooks for this purpose
Parameters:
  type - fully qualified class name true if simple value, false if not



main
public static void main(String[] args) throws JiBXException, IOException(Code)
Run the binding generation using command line parameters.
Parameters:
  args -
throws:
  JiBXException -
throws:
  IOException -



writeBindings
public void writeBindings(File dir) throws JiBXException, IOException(Code)
Write the bindings to supplied destination path.
Parameters:
  dir - target directory for writing binding definitions, output toconsole if null
throws:
  JiBXException -
throws:
  IOException -



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.