I want to make a component model using Eclipse (and possibly some plugins?) - and the corresponding object-model for the objects within the component. This web page has an example of the component model and object model I am trying to produce.
http://www.agilemodeling.com/artifacts/componentDiagram.htm (please look at the diagrams)
To be honest I am new to eclipse. I want BOTH the diagram and the classes and interface definitions as well (not just a picture). But I also want the picture..... not just class and component definitions. I'm running on Windows.
Are there special plugins for diagrams?
Are there special plugins for component models?
How in Eclipse do you place the classes in a component?
Any links to examples (other than the one I have), would be so appreciated!!
Thanks In Advance!!
Alex
Related
I am using Sparx Enterprise Architect and am somehow confused that I did not find any hint on the internet regarding the following question: How can I show the programming language of a component in the component diagram?
It is clear to me that I could use custom stereotypes but this is not a good idea as it prevents me from using "real" stereotypes later on.
The reason is simply that you can not show it using EA's GUI. You would need to stereotype the element and come up with a shape script to display the language with a
print("#language#");
somewhere.
To assign a shape script to a stereotype there are two ways, the quick and dirty and the difficult one. Here's the q&d one:
Under Configure/UML Types you can add a new 'wild' stereotype. That is one with no profile. EA will show that as <none> when applied. Think of a fitting name and choose Edit with the shape script:
Here can enter the new shape script (since this depends very much here's a simple one):
shape main {
Rectangle(0, 0, 100, 100);
println("#name#");
println("#language#");
}
Save the edit and close the dialog. Once you assign the stereotype to an element it will render like this:
I know this is not pretty and you need to dig into shape scripts to make it useful, but that can't be avoided.
So the difficult, but better and preferred, way is to create your own profile containing the stereotype along with the shape script. The above would just be a way of testing it but finally you would need to create your profile and put it in a MDG. Since this is a quite complex task it won't go here into this answer (no, I'm not Fermat, but you need quite some effort to get that far).
There is no standardized way to show the programming language of a component in UML. There are several ways you can do it, for example:
Stereotype. This will not prevent you from adding other stereotypes in the future. Multiple stereotypes are shown comma separated: «stereotype1, stereotype2»
Generalization. You can define a component called 'JavaComponent' and let all Java components inherit from this base component.
Note. You can attach a note to the component specifying the language.
How can I extend the functionality of the UML designer?
I want to be able to load some specific class file and show the infos(attributes, relations) into the UML Diagram?
Thanks!
As UML Designer is based on Eclipse Sirius, you need to update the diagrams specification : uml2.odesign.
If you don't know yet Sirius, you can have a look to the get started page.
If you have more specific questions do not hesitate!
I have a file very big file .umlclass. It has a lot of classes, Enumerationtypes, relations.... I want to organize it in the class diagram Editor, but it is impossible because I don't know where the things are.
In the Project Explorer of Eclipse I can see the tree and in the view properties I can see the properties of each one, but I can't see it in the class diagram Editor.
Is there any kind of select or find each resource in the diagram Editor? I'm using the UML2Tools plugin.
Thanks in advance.
Ramón.
Actually the UML2Tools don't have a full fledged editor. Consider using another editor for your Eclipse UML2 Model.
Omondo EclipseUML can read all UML2Tools model.
You just need to to create an empty class diagram and drag and drop one classifier inside the diagram. The project will immediately import all models and then allow you to navigate graphically in the model using the class diagram as a viewer of your model.
It is really good because your diagrams are not anymore the model itself as it is for many tools but only a viewer of your model.
Really cool feature :-)
I would like to find the best way to parse an UML Diagram that detail the security tomcat configuration for a web application, then generate the concerned file (web.xml).
For the beginning, I have a Metamodel and his instance created with Magic Draw, I have to export them and use them in a kind of java application (plugin? API?) then parse and validate them against some constraint (OCL?) finally I have to generate the Web.xml file.
So, I made some research and I found that I can use EMF to catch my models, but its not so clear and handily to create a peace of java code that can handle my model remotely from an URI then validate em.
Do you have any suggestions/advises to made this please? Do I must use EMF? or there is another framework?
Thanks
web.xml from UML? Sorry, I don't think it's a useful idea. It doesn't take long to hand edit such a thing. The effort it would take to automate such a thing wouldn't be worth it. I'd open up a text editor, create the web.xml, and spend the time you save doing more useful things.
But, if you must, I'd find a way to export your object model into an XML document. I'd parse that into a DOM tree, walk the tree, and emit the elements I needed into a web.xml.
I know that Magic Draw has the capability to export UML as XML. See if that helps you.
But there's no way to do it directly from the Magic Draw tool that I know of. You'll have to write this Java post-process and run it on the command line using the exported model XML as input.
I'm Using Papyrus UML and I have to use in my diagram, a class which is defined in another .uml file. HowI can do it?
Thank you
You need to create a shortcut but for me this is not usable because I prefer to mix usecase and class diagram elements inside the same model and sometimes even the same diagram.
You can do it with RSA IBM or Omondo EclipseUML.
I do not know particularly about Papyrus, but in UML in general, you should have a Model-element at the top-level, and in there, you create a PackageImport. Now you should be able to set the ``Imported Package'' reference---but the other UML must be loaded from the workspace first:
This is where things become interesting! in the plain Eclipse UML editor, you have to load the resource first using the 'UML Editor' menu or the ``Additional Resources'' sub-tree in the model-outline. I guess Papyrus offers at least the same way through the outline.