directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ole Ersoy (JIRA)" <>
Subject [jira] Commented: (DIRSTUDIO-232) DAO Generator
Date Thu, 25 Oct 2007 20:14:50 GMT


Ole Ersoy commented on DIRSTUDIO-232:

The Tuscany LDAP DAS does this and it is written for ApacheDS.  You would take an XML Schema
that is the model for the data and use it to generate the code via Eclipse EMF.  Then you
just populate a model (For instance the model could be of the ADS server.xml file, assuming
it had a schema) and call LDAPDAS.write(modelInstance)...and it will store it in ADS.

I still need to write the users guide, but the tests are fairly thorough, in case anyone wants
to give it a shot.   I'll also be glad to answer any questions of coarse.

So say for instance you wanted to store a Maven pom.xml file in ApacheDS.

You would first take the maven xml schema modeling the pom.  Generate the corresponding java
class model using EMF (Maven uses modello instead).  Use the EMF API to load an instance of
a pom.xml file, and store it in say a reference called mavenProjectReference.  Then call LDAPDAS.write(mavenProjectReference);
 And that's it.  Now that pom.xml file is stored in ApacheDS.

> DAO Generator
> -------------
>                 Key: DIRSTUDIO-232
>                 URL:
>             Project: Directory Studio
>          Issue Type: New Feature
>            Reporter: Christine Koppelt
>            Priority: Minor
> The Data Access Object (DAO) design pattern offers a method for seperating the access
to data from the underlying data stores. One of the disadvantages of this patter is, that
the implementation requires a lot of code to be written.
> There already exists some code generators which generate java code for accessing data
from RDBMS according to this pattern. For example:
> It would be quite cool to add such a DAO code generator to Studio for accessing data
from LDAP servers.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message