Book a Demo

Author Topic: Issues with Java code generation  (Read 3370 times)

judge

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Issues with Java code generation
« on: June 15, 2006, 07:45:00 am »
Hi,

I have a couple of issues with the Java code generation:
  • The name of the view is included in the package declaration. Is that really the purpose of a view?
  • I have a bunch of class diagrams in the root of the view with interfaces on them that are from some package. When I generate code from the element on the diagram the package isn't included in the package declaration.
  • The diagram shows associations for the element with other classes/interfaces. If I generate from the diagram members are created for those associations. If I generate from the element in the tree view, no members are created.

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Issues with Java code generation
« Reply #1 on: June 16, 2006, 05:05:42 am »
Hi Judge,

I don't have the answer to your third question.

The first two look like they are the results of not setting a package in your model to be the namespace root. There is some fairly limited mention of this in the EA user guide. If that is not enough for you to solve the problem, search the EA forum (all sections) for information on this. You might have to try several keyword combinations, but you will find what you need.

David
No, you can't have it!

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Issues with Java code generation
« Reply #2 on: June 18, 2006, 03:26:48 pm »
David is likely correct about your first two problems.  I'd recommend reading http://www.sparxsystems.com.au/EAUserGuide/index.html?namespaces.htm to get a better understanding of how EA handles namespaces.

I haven't seen anything like your third issue.  Are you sure that the diagram and tree elements are actually the same?  It's probably sending in a bug report, an attached model would definately help us to find the problem.