Custom Schema
Warning | ||
---|---|---|
| ||
This page needs to be overworked |
...
No Format |
---|
svn co http://svn.apache.org/repos/asf/directory/apacheds/releasestags/1.0.12/schema-archetype/ cd schema-archetype mvn install |
Once the archetype is installed you can now generate a schema project with it. Let's presume we want to generate a schema project where our schema is in a package called com.acme and the generated artifact's id is foo-schema. You can either use Maven directly to generate this project or you can use the shell script that's sitting in the schema-archetype directory you just checked out. Here's how to get Maven to generate your foo-schema project for the com.acme package and groupId:
No Format |
---|
mvn archetype:create -DarchetypeGroupId=org.apache.directory.server \ -DarchetypeArtifactId=apacheds-schema-archetype \ -DarchetypeVersion=1.0.0 \ -DgroupId=com.acme -DartifactId=foo-schema .sh com.acme foo-schema |
Warning |
---|
To make this command working, you must be in another directory than the schema-archetype directory. For instance, after the first command (mvn install), just cd to the parent directory : |
Once you've generated with success you'll see a new foo-schema directory created. This is the maven module that will generate your schema file. From the onset we included an example schema called car.schema which has a few attributeTypes defined and a car objectClass. It's there as a placeholder. Before we go into how to customize this stuff let's look at the tree of the new project:
...