Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » Re: Model Reader - Documentation issue.
Re: Model Reader - Documentation issue. [message #626547] Fri, 09 May 2008 06:24
Ed Merks is currently offline Ed Merks
Messages: 26010
Registered: July 2009
Senior Member
Rajasekar,

Oops. Sorry for the previous mis send. This sounds like purely a UML
issue so I've added the UML2 newsgroup to the to list of the reply.
It's best to ask UML2 questions there.


Rajasekar M wrote:
> We have developed One plugin using EMF Framework. We are facing some
> issues while importing model.
>
> Each model will have field, relationship and field map. Field will
> have doc tag associated which will have comment for the field.
>
> eg.. <field name="AreaCode" scope="all">
> <properties label="{RESOURCE}"/>
> <type class="string3" required="true"/>
> <doc><![CDATA[3 digit Area Code]]></doc>
> <persistence dbName="AREA_COD"/>
> </field>
>
> When we import this model using our plugin, we could not see the
> comment "3 digit Area Code" on the documentation tab for the model.
>
> The below is source we used for reading model while import.
>
> private void processDoc(final DomainElement domainElement,
> org.eclipse.uml2.uml.Element element) {
> final List<Comment> commentList = element.getOwnedComments();
>
> final StringBuffer comments = new StringBuffer();
> for (Comment comment : commentList) {
> comments.append(comment.getBody());
> }
>
> domainElement.setDocumentation(comments.toString());
> }.
> The below piece of code is copied from .emx file.
>
> <ownedAttribute xmi:id="_kflz8aRHEdyRJ-yMLomXrA" name="AreaCode">
> <ownedComment xmi:id="_kgyGwKRHEdyRJ-yMLomXrA">
> <body>3 digit Area Code</body>
> </ownedComment>
> </ownedAttribute>
>
> Also, we have identified, when we enter comments in the RSA editor and
> save the model there is attribute called annotatedElement is added to
> the ownedComment tag.
>
> <ownedAttribute xmi:id="_kflz8aRHEdyRJ-yMLomXrA" name="AreaCode">
> <ownedComment xmi:id="_kgyGwKRHEdyRJ-yMLomXrA">
> <body>3 digit Area Code</body>
> </ownedComment>
> <ownedComment xmi:id="_nT6mgB15Ed2rhYiAzgNSyQ"
> annotatedElement="_kflz8aRHEdyRJ-yMLomXrA">
> <body>Test Documentation</body>
> </ownedComment>
> </ownedAttribute>.
>
> Please help me in this issue.
> Thanks,
> Rajasekar.
>
>
Previous Topic:UML2 from eclipse and customer requirements
Next Topic:translating java annotations to an UML repesentation
Goto Forum:
  


Current Time: Wed Aug 27 15:09:19 EDT 2014

Powered by FUDForum. Page generated in 0.01762 seconds