Book a Demo

Author Topic: Diagram element marking  (Read 7264 times)

Dima

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Diagram element marking
« on: December 05, 2007, 09:33:43 am »
Frequently I start with creating diagrams by placing elements and connecting them together.

After that I come back and add details to each element.

It would be nice to see some kind of "mark" on an element that will indicate that the element has any content besides name or not.

This will allow me quickly identify what to work on. In addition if I generate HTML site - the reviewer will immidiatly know what to drill-down to to see details.

Is there existig feature? Is it possible to include this in one of the next releases?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Diagram element marking
« Reply #1 on: December 05, 2007, 01:15:15 pm »
Dima,

I don't think there is any feature that is quite like you describe. However, I can suggest several ways you might be able to go about this without too much work.

EA allows you to assign some properties to an element that go beyond what UML requires. You can assign keywords, but these are kind of free-form, and not quite automatic. However...

You can assign a Status [capitalized to match the element Properties dialogs] to any element. EA generally defaults the value of this property to "Proposed." This default value might work just fine for you. There are a standard set of Status values, and you can add your own via the Settings | General Types dialog (which defaults to the Status tab). Note that there is also a Constraint Status tab, allowing you to handle constraints separately.

If you set up your own Status values, they are stored as Reference Data, and may be exported and loaded into other projects.

[Note that the default is (probably) set in the EABase project that is installed with EA. You could edit this project to set up a different default, which could be one of your custom values.]

The nice thing about setting a Status value, is that EA can use these values to highlight elements. You will generally see this in regards to Requirement elements and such, but EA will actually allow you to highlight just about anything.

You enable this in a three step process. [You can do this in fewer steps, but it sometimes helps to explain it this way the first time.] First open the Tools | Options | Objects dialog, and check the box labeled Show status colors on diagrams. Now go (back) to the Settings | General Types dialog (and the Status or Constraint Status tab as appropriate). For each Status value you intend to use, click the Applies to button, and check the element types you want to highlight. Each Status value can be set independently. In many cases, such as Requirement elements, you're all done.

Now for the third (and most mysterious) step. For many elements (such as Class elements) the status color will only show if EA is drawing element shadows. So, you need to turn this setting on. You'll find the setting back on the Tools | Options | Objects dialog; check the Shadows On box.

If the Status method doesn't work for you, perhaps you can assign a stereotype of «draft» or something, when you first create an element. You can accelerate this process by adding the stereotype to the Settings | UML | Stereotypes dialog. This way it will appear on the Stereotype drop-down of the element's properties dialog. You can type the first letter or two and press the down arrow key; EA will do the rest.

If you use a stereotype, make sure you don't have EA set to ignore stereotypes when rendering a diagram. [Or, make sure you do have EA ignore it if you want to display diagrams without it for some reason.] The setting you need is on the Elements tab of the diagram Properties dialog. Check or clear the Show Element Stereotypes box. There is also a setting for features (attributes, operations, and such). It is names Show Stereotypes, and is found on the Features tab.

There's a related setting on the Tools | Options | General dialog. If you check the Show Stereotypes box in the Project Browser settings, you will see your stereotype (and any others) in the Project Browser tree. You should set this as appropriate for your needs.

Finally, you can bookmark the element. EA uses bookmarks to draw your attention to an element for quick reference, which is what you want to do here. To set a bookmark, highlight an element and press Shift-Space. You'll see a little red triangle at the top of the element. To remove a bookmark, do the same thing again: select the element and press Shift-Space.

[BTW, bookmarks - or more accurately the "little red triangles" - are one of the least understood features of EA. What the "triangles" mean, where they come from, and most importantly how to get rid of them, are among the most common user questions.]

Note that any or all of the above can be used in combination.

HTH, David
No, you can't have it!

Dima

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Diagram element marking
« Reply #2 on: December 05, 2007, 02:46:21 pm »
WOW!!!

Thanks David for so detailed answer! I really appreciate this!

I have played with Statuses, but it seems to only work for Requirements, which I use extensively. Other elements don't seem to show colors - I will try your three step process.

I think your bookmark idea is also a good one.

I will keep you posted though.

In general, it would be nice to extend EA color functionality. For example, I would be able to set GREEN for all elements that have e.g. Phase=2.1

This way I could set a color for Note = '' to implement my need, but also implement whole range of tasks. Is there a way to submit a request for enhancement like this?

Dima

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Diagram element marking
« Reply #3 on: December 05, 2007, 03:22:24 pm »
Thanks for the ideas. I did try something like that. But I'm trying to solve different issue. It's not that I'm trying to show or hide details.

Here is example, I came across today:

I've been putting together Use Case diagram and quickly drafted 15 use cases, with 3 actors. Some of them had scenarios entered while creating an element, some of them not. So, now I'm looking at it and in order to find out what I still need to specify - I have to open EVERY use case and switch to Scenarios tab.

The difficult part is that when I open it two days later  - I have to do it again for EVERY use case. And when I send it to someone - they have to so it for EVERY use case or I have to maintain separate list of what is done and what is not.

Status Color idea may work - the weird part that it changes color of a shadow not object itself!  

Quote
When you say "come back and add details" you can set the diagram options to display the details that exist. Therefore if the element doesn't show the details, you can assume the details haven't been added yet. This is a simplistic solution, but it avoids the problem of other people trying to remember what a status color or suchlike implies.

Right-click on the diagram background and select the Properties option, and click on the Elements tag, and select as many checkboxes as you require. You can select to show attribute details and parameter details too, on the Features tab.

How would that work for you?


Dima

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Diagram element marking
« Reply #4 on: December 05, 2007, 03:24:57 pm »
I tried Statuses and it's probably going to work unless there is something else better.

One additional question - can I customize HTML template - so when it generates HTML - it would add special mark based on the object status? Does anyone have an example how to do something like this?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Diagram element marking
« Reply #5 on: December 05, 2007, 04:10:03 pm »
Quote
Thanks for the ideas. I did try something like that. But I'm trying to solve different issue. It's not that I'm trying to show or hide details.

Here is example, I came across today:

I've been putting together Use Case diagram and quickly drafted 15 use cases, with 3 actors. Some of them had scenarios entered while creating an element, some of them not. So, now I'm looking at it and in order to find out what I still need to specify - I have to open EVERY use case and switch to Scenarios tab.

The difficult part is that when I open it two days later  - I have to do it again for EVERY use case. And when I send it to someone - they have to so it for EVERY use case or I have to maintain separate list of what is done and what is not.

Status Color idea may work - the weird part that it changes color of a shadow not object itself!  


Take a look at Set Feature Visibility. You'll find this by selecting one or more elements on a diagram then right-clicking to bring up a context menu. Unfortunately this won't help you for use cases.

I don't know if this will help you with scenarios, though.

Look into Note Links. I'll leave you to scan the documentation. This is a bit different than you describe, but it works well with scenarios - actually with a single scenario for a given use case, I think.

I suspect - entirely without proof - that EA uses the shadows for custom colors in order not to run afoul of UML notation. For things like requirements, issues, and (product) features, EA handles this in its own way, since these are somewhat customized extensions to UML.

Remember that you can change the colors that EA uses for Status values, as well as creating your own Status entries and assigning colors to them. You can also create customized color pallets for EA, and switch between them. Remember as well that these are Reference Data, and can be exported and imported into other projects.

Now the bad news: EA will not go back and update the work you've done so far. Try something like bookmarks though; they are fast and easy to set and remove, so little time is required. At the very least you can limit the overhead of checking each entity (such as the use cases you mention) to yourself, saving your readers the trouble. Just remember to tell them what the bookmark indicates.

BTW, for what it's worth you can do yet another trick for feature (attribute, operation, and such) stereotypes. On the Set Feature Visibility dialog you can turn off the display of specified stereotypes. This works on an element-by-element basis, but you can set several or all of the elements on a given diagram by selecting them all before you invoke the dialog.

[This is one of the few areas where multiple select and edit works (yet) in EA. If you want more of this, please browse to some of the relevant threads in the Suggestions section of the forum and add your support; also please submit a feature request to Sparx to add even more weight.]

I think that EA will 'remember' the most recent setting for feature stereotypes, and apply it to new elements, but I could be wrong there. I'll leave you to experiment, since you're doing an evaluation anyway.

HTH, David
No, you can't have it!

peter.zrnko

  • EA User
  • **
  • Posts: 253
  • Karma: +0/-0
    • View Profile
Re: Diagram element marking
« Reply #6 on: December 14, 2007, 06:24:11 am »
Quote
I have to open EVERY use case and switch to Scenarios


You can open the "Rules and Scenarios" window. It can save you a little time, when searching for scenarios.
Peter