Class SchemaToJava
- java.lang.Object
-
- org.springframework.ldap.odm.tools.SchemaToJava
-
public final class SchemaToJava extends java.lang.ObjectThis tool creates a Java class representation of a set of LDAP object classes for use withOdmManager.The schema of a named list of object classes is read from an LDAP directory and used to generate a representative Java class. The Java class is automatically annotated with
org.springframework.ldap.odm.annotationsfor use withOdmManager.The mapping of LDAP attributes to their Java representations may be configured by supplying the
-sflag or the equivalent--syntaxmapflag whose argument is the name of a file with the following structure:# List of attribute syntax to java class mappings # Syntax Java class # ------ ---------- 1.3.6.1.4.1.1466.115.121.1.50, java.lang.Integer 1.3.6.1.4.1.1466.115.121.1.40, some.other.Class
Syntaxes not included in this map will be represented as
Stringif they are returned as Strings by the JNDI LDAP provider and will be represented asbyte[]if they are returned by the provider asbyte[].Command line flags are as follows:
-c,--class <class name>Name of the Java class to create. Mandatory.-s,--syntaxmap <map file>Configuration file of LDAP syntaxes to Java classes mappings. Optional.-h,--helpPrint this help message then exit.-k,--package <package name>Package to create the Java class in. Mandatory.-l,--url <ldap url>Ldap url of the directory service to bind to. Defaults toldap://127.0.0.1:389. Optional.-o,--objectclasses <LDAP object class lists>Comma separated list of LDAP object classes. Mandatory.-u,--username <dn>DN to bind with. Defaults to "". Optional.-p,--password <password>Password to bind with. Defaults to "". Optional.-t,--outputdir <output directory>Base output directory, defaults to ".". Optional.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidmain(java.lang.String[] argv)
-