Book a Demo

Author Topic: Features, Requirements, and Business Rules  (Read 4457 times)

bioform

  • EA User
  • **
  • Posts: 230
  • Karma: +0/-0
  • Forty-Two?
    • View Profile
Features, Requirements, and Business Rules
« on: December 27, 2006, 08:01:34 pm »
Okay, with Build 801 the release notes say... "Added ability to create Requirement metaclasses in UML Profile models"

Sounds good, previously could not stereotype a requirement within EA, so was unable to create a Business Rule stereotype that way (used an XML file defined manually to create it...)

EA uses the "Type" field to indicate the stereotype for the base class "Feature" & "Requirement." But I can't seem to get "Synch Tagged Values and Constraints..." to have an affect.

HOW do I use this new capability the release notes describes?

My goal is actually pretty simple:

Add Tagged Values: Risk & Priority to Feature & Requirement, then create a stereotype of Requirement as "Business Rule" with a tagged value that indicates "BR_Kind"...

Any suggestions, thoughts, or insights?!!

Thanks!
Time is what keeps everything from happening at once, Space is what keeps it all from happening to you. <unknown>

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Features, Requirements, and Business Rules
« Reply #1 on: December 28, 2006, 05:33:23 am »
Are you sure you are using this to build a profile - in the EA sense of the word - and not just as a 'normal' stereotype?
No, you can't have it!

bioform

  • EA User
  • **
  • Posts: 230
  • Karma: +0/-0
  • Forty-Two?
    • View Profile
Re: Features, Requirements, and Business Rules
« Reply #2 on: December 28, 2006, 09:21:09 am »
Well I understand you can create a sterotype two ways...

1. Create a diagram using the "Profile" tool set and then linking the stereotype with the base class using "redefinition" or "extend" as the relationship between the stereotype and the base class. Then exporting the "profile" and importing it into another (or the same) project... The advantage to this method is you can maintain the profile, add tag values, etc. as needed, then update a model that makes use of these stereotypes using the "Synch Feature" for ALL of them, or Drop the stereotype on a base class to "convert" it and only it to the stereotype...

2. Create a stereotype using "Settings | UML | Stereotypes" , BUT you cannot add tagged values to the stereotype here... ONLY using the "Profile" approach can you propogate changes across the model using "Synch..."

If you have created your stereotype using the first method, and loaded the profile, you can then use this process to change it's default appearance...

That sound about right?

My issue is if I modify the Feature/Requirement base class or create a stereotype that the "Synch..." feature does not appear to work.

My UC stereotype I created (using the Profile approach)works just fine!
Time is what keeps everything from happening at once, Space is what keeps it all from happening to you. <unknown>

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Features, Requirements, and Business Rules
« Reply #3 on: December 28, 2006, 03:55:11 pm »
Just tried it and "Synch Tagged Values and Constraints" command works for Requirement, Issue and Change elements but not for Feature elements. We will fix it.
The Sparx Team
[email protected]

bioform

  • EA User
  • **
  • Posts: 230
  • Karma: +0/-0
  • Forty-Two?
    • View Profile
Re: Features, Requirements, and Business Rules
« Reply #4 on: December 28, 2006, 04:27:29 pm »
Okay, I went ahead and created a stereotype of the base class "requirement" (extend), and named it requirement...

Exported the profile and imported into a project...

Dragged a requirement (call it A) from a tool set onto a diagram... (it's default setting for the "Type"  attribute was set to "Functional" from the "Settings|General Type|Requirements" definitions...

Dragged a requirement (call it B) from the profile, onto a diagram... (it's default setting for the "Type"  attribute was set to "Requirement" based on the stereotype of the pofile...

Now.. B has two tagged values on it (from the profile), I delete one, then try to synch... WORKS...

Now IF I change A's "type" value from "Functional" to "Requirement", then resynch it works fine...

BUT... since the type field is used to capture the requirement type aka as category (using the Settings|General Types|Requirements) it would seem, that this functionality is no longer really valid...

Because I would have to change ALL non-stereotyped requirements to the value "Requirement" (not in the list), Sych them... but in the process I would loose the information that describes their type...

NOT sure of a valid workaround (other than via SQL queries... store current value locally... run SQL query to change "type" to "requirement"... Update tag values & constraints using Synch... run SQL query to change "type" back to stored value...

Maybe I should just forget stereotyping these two elements (or any others that use type attribute to store categorization information in the stereoptype field of the object table), and just run a SQL query to mapped my tagged values onto the object's with a type of feature or requirement?

This seems to be a problem because the Feature & Requirement object's use the "stereotype" column of the object table to store the value of the "type" attribute exposed in the Feature/Requirement property UI...

Viable workaround could be to create a tagged value that represents the "type" value add it to the requirement & feature stereotype along with "risk" & "priority", and leave the Feature/Requirement type field value always reflecting the requirement stereotype name...
Time is what keeps everything from happening at once, Space is what keeps it all from happening to you. <unknown>

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Features, Requirements, and Business Rules
« Reply #5 on: December 29, 2006, 12:36:59 am »
bioform,

One way out of your problem may be to make use of EA's ability to handle multiple stereotypes.  [caveat]We haven't got around to profiles yet, we're still too busy diagnosing XMI RTE bugs   But we're likely to head down the profile track soon.[/caveat]

If you haven't used it in the past, then search the forum for "multiple stereotype",  In particular, you may wish to view [size=13]IDEA: Evolution of multiple stereotypes[/size].

Now EA's support for multiple stereotypes is a bit spotty but...  If the Synch Tagged Values and Constraints works for auxiliary (that is, other then primary) stereotypes, then the problem is how to apply multiple stereotypes to these special elements.

This is achieved by using the Properties [Alt+1] window.  The Stereotype entry has a drop down that includes browse other stereotypes... entry.  This will open the Stereotype for <element> dialog and you can set multiple entries there.

If the Synch Tagged Values and Constraints doesn't work for auxiliary stereotype then this should be reported to Sparx as a bug.

If you do conduct the experiment, can you report your findings here?

HTH,
Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!