cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nikita Timofeev (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CAY-2333) Project XML extensions
Date Fri, 13 Oct 2017 09:16:00 GMT

     [ https://issues.apache.org/jira/browse/CAY-2333?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Nikita Timofeev updated CAY-2333:
---------------------------------
    Fix Version/s:     (was: 4.1.M1)
                   4.1.M2

> Project XML extensions
> ----------------------
>
>                 Key: CAY-2333
>                 URL: https://issues.apache.org/jira/browse/CAY-2333
>             Project: Cayenne
>          Issue Type: Improvement
>          Components: Modeler, Non-GUI Tools
>    Affects Versions: 4.1.M1
>            Reporter: Nikita Timofeev
>            Assignee: Nikita Timofeev
>             Fix For: 4.1.M2
>
>
> Cayenne need flexible project XML extensions mechanism to allow attach some meta information
to project, that will not affect runtime.
> Use cases can be following:
> * General comments for entities, attributes and relationships
> * Reverse engineering config
> * Cgen config
> * ER and Class diagram
> Possible linked tasks CAY-400 and CAY-56
> Here is main API for project extensions:
> {code}
> public interface ProjectExtension {
>     /**
>      * @return delegate that handle loading phase of XML processing
>      */
>     LoaderDelegate createLoaderDelegate();
>     /**
>      * @return delegate that handle saving phase of XML processing
>      */
>     SaverDelegate createSaverDelegate();
> }
> public interface LoaderDelegate {
>     /**
>      * @return target namespace that this extension is using
>      */
>     String getTargetNamespace();
>     /**
>      * Create handler that will handle parsing process further.
>      */
>     NamespaceAwareNestedTagHandler createHandler(NamespaceAwareNestedTagHandler parent,
String tag);
> }
> public interface SaverDelegate extends ConfigurationNodeVisitor<Void> {
>     /**
>      * @param encoder provided by caller
>      */
>     void setXMLEncoder(XMLEncoder encoder);
>     void setParentDelegate(SaverDelegate parentDelegate);
>     SaverDelegate getParentDelegate();
> }
> {code}
> Extension can be contributed via {{ProjectModule.contributeExtensions(Binder)}} method.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message