Author Topic: Business Rules  (Read 7798 times)

NicoleL

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Business Rules
« on: August 23, 2004, 05:52:06 pm »
My colleageus and I can't really find a good place in EA for the Business Rules associated with the Use cases. So far nothing has jumped out at us in the Use cases.

Are we completely missing something?

Thanks,
Nicole

CJ

  • EA User
  • **
  • Posts: 288
  • Karma: +0/-0
    • View Profile
Re: Business Rules
« Reply #1 on: August 24, 2004, 05:12:21 am »
G'day,

EA can probably support a huge set of options to enter business rules into your model.

I'd be tempted to say use the Class element, stereotyped as <<Business Rule>>.  Then, you can take advantage of attributes, operations (?), internal requirements, constraints, tags, scenarios, etc. to really document the rules to the hilt.

If that's overkill, then maybe a Requirement element, again stereotyped as <<Business Rule>>.

Do a search of the forum for other threads on business rules.  Here's one:
http://www.sparxsystems.com.au/cgi-bin/yabb/YaBB.cgi?board=UMLPRO;action=display;num=1083322899;start=0#0
Cheers and best regards.

didver

  • EA Novice
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: Business Rules
« Reply #2 on: April 11, 2006, 11:58:17 pm »
Hi,

"a Requirement element, stereotyped as <<Business Rule>>"
How can I do this with EA ?

Thx,
Didier

mikewhit

  • EA User
  • **
  • Posts: 608
  • Karma: +0/-0
  • Accessing ....
    • View Profile
Re: Business Rules
« Reply #3 on: April 12, 2006, 12:39:53 am »
http://www.sparxsystems.com.au/EAUserGuide/creatingcustomstereotypes.htm

Sorry that's too simplistic - I was just passing !
« Last Edit: April 12, 2006, 05:02:25 am by mikewhit »

didver

  • EA Novice
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: Business Rules
« Reply #4 on: April 12, 2006, 12:49:09 am »
Yes, this allows me to create the custom "business rule" stereotype. But how do I stereotype the requirement element ? (there's no drop down list in the properties tab like there is in the general tab of a class element, isn't it ?)

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #5 on: April 12, 2006, 04:35:25 am »
Didier is correct. There's no apparent mechanism for getting the stereotype assigned to the requirement. Nor does there appear to be a way to modify this behavior through the Stereotypes dialog.

Creating a stereotype designed for requirements has no effect, since the requirement won't allow assignment, and other base classes won't pick up that stereotype.

Nor does there appear to be (at least to me, so don't take this on faith, I'd love to be corrected) a simple way to stereotype a class (or some other 'common' element) to make it a requirement; if there were we could add an additional stereotype and see if that got us someplace.

Any ideas?
No, you can't have it!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8607
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Business Rules
« Reply #6 on: April 12, 2006, 05:10:04 am »
Quote
Didier is correct. There's no apparent mechanism for getting the stereotype assigned to the requirement. Nor does there appear to be a way to modify this behavior through the Stereotypes dialog.

Creating a stereotype designed for requirements has no effect, since the requirement won't allow assignment, and other base classes won't pick up that stereotype.

Nor does there appear to be (at least to me, so don't take this on faith, I'd love to be corrected) a simple way to stereotype a class (or some other 'common' element) to make it a requirement; if there were we could add an additional stereotype and see if that got us someplace.

Any ideas?
Remember folks,

There are two kinds of Requirements in EA - Internal and External (to the Element).
Internal Requirements are actually Responsibilities (of the Element).  (See: Export Requirements to Excel)

External requirements can have stereotypes added by a circuitous route.  Change the Element type to Class, set the stereotype and reset the type back to Requirement.
(You can also set the stereotype value directly via the database - usual caveats)

[David, this is another example of the incorrect inheritance hierarchy - if I can do it by the circuitous route, why can't I do it directly?  ::)]

Internal requirements (Responsibilities) are NOT elements - and thus CAN'T be stereotyped.

HTH,

Paolo
« Last Edit: April 12, 2006, 05:11:54 am by PaoloFCantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #7 on: April 12, 2006, 05:20:06 am »
Thanks Paolo,

Still, this leaves me in a quandary (someplace I'm both familiar and comfortable).

When I create a requirement element from the toolbox (custom or requirements panel) I get what seems to be the internal requirement you mentioned. I cannot change element type, etc.

How do I create an external requirement? The user guide mentions both entities, but seems to be secretive about how to handle this.

Of course, I could be looking in the wrong place. Still, that is more likely YA indicator that the user guide is getting to the point where a total overhaul is necessary.

Yes, I agree about the EA Unique Interface. We live in hope...

David
No, you can't have it!

didver

  • EA Novice
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: Business Rules
« Reply #8 on: April 12, 2006, 05:27:04 am »
David,

I believe the requirement from the toolbox is the external one ; while the internal one is the reponsability (in the responsabilities tab of an element).

Didier

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #9 on: April 12, 2006, 05:59:26 am »
So far so good Paolo,

I can change the element type via the Element menu, but not via the context menu. This has always been the case, but I forgot.

It appears that the element type for a requirement, internal or external, is always Class. When I create an external one, by clicking "Move External" on the Class dialog, I get a requirements icon, but with no apparent invisible (wait for it) stereotype.

When I create a requirement via the toolbox I get a requirement with a <<Functional>> stereotype; note that the capitalization seems to matter to EA. It (the stereotype) is visible in the Project View tree if your preferences are set for this. Note however that this stereotype is not listed in the Stereotypes dialog, and is 'invisible' on the element itself. (There is, however, a requirement stereotype for comments, but I digress...)

I can change the Class back into a Requirement, and so far things seem to work.

Now, can you remember how to set multiple requirements? I just cannot seem to get this right, and thus cannot retain the Functional stereotype.

Still, this is progress.

Nicole (if you're still listening) and Didier, does any of this help?

David
No, you can't have it!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8607
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Business Rules
« Reply #10 on: April 12, 2006, 06:25:11 am »
Multiple stereotypes are created via the little builder button [...] to the right of the stereotype dropdown.

The stereotype in the drop down is the primary stereotype.  The others are auxiliaries.  However, if you uncheck the primary stereotype (in the auxiliaries list), it appears the alphabetically first auxiliary stereotype will be assigned as the primary.  HOWEVER, if you clear the primary stereotype in the dropdown, it remains set in the auxiliary list   ::)   At present ONLY the primary is visible in diagrams and the project explorer.

You can only do this whilst in type Class.  (..and DON'T try this on your database as the additional stereotypes are NOT stored in the Stereotype field.)

HTH,

Paolo
« Last Edit: April 12, 2006, 06:25:26 am by PaoloFCantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #11 on: April 12, 2006, 08:48:07 am »
Thanks Paolo,

It's always been there, and I have actually used it before (before time began, that is). Still, my brain (as we laughingly call that bone in my head) is trained to somehow associate the button the "Abstract" caption that it abuts. Even though I never have any urge to click the button to set a class to abstract, the blind spot remains.

Also, very much thanks for the pointers on how EA handles (?) primary stereotypes.

David
No, you can't have it!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #12 on: April 12, 2006, 08:59:50 am »
Hey folks...

We could always open the Settings / General Types / Requirements dialog and add BusinessRule as a requirements type. Then we could choose BusinessRule from the Type dropdown on the Properties dialog for a specific requirement.

We're still left with a rather bland display, since we cannot distinguish between these and other requirements (or even see any requirement types). Perhaps this is best brought up via the Request a Feature dialog in On-line Resources.

Who's got the most thinking into this so far? That would be the best person to dial Sparx. [Not me, since I cannot even find the button...]
No, you can't have it!

nara_c

  • EA User
  • **
  • Posts: 45
  • Karma: +0/-0
    • View Profile
Re: Business Rules
« Reply #13 on: April 12, 2006, 05:50:56 pm »
Folks another option is to create a UML Profile using EAs extension mechanism and create a new Sterotype called "Business Rules".  

There are many advantages to this approach.  

1) You can set up the profile to appear on your toolbar and then just "drag and drop" like you do for "Requirement" or "Feature" and voila you have the stereotype pre-applied saving all the extensive work arounds suggested.

2) You can add additional tagged values to the "Business Rule" requirement type.  Something that is not possible currently. In addition tagged values can be forced to pick from a List of values and thus control the values that can be entered.

3) If for some reason in future you decide to increase the tagged values fields, you can do so in the profile and then propogate to your existing model.

IMHO UML Profiles are a very powerful mechanism to extend UML and EA has done a great job of enabling users to create these profiles easily.  

Refer UML Profiles in the help file or "http://sparxsystems.com.au/EAUserGuide/umlprofiles.htm" for more details.

If you want a sample Requirements profile to demonstrate this post your email ID or send me a private message and I will send it to you.  

I tried uploading it to the EA users sharepoint site but realised I do not have permission to add new announcements.  I have raised a request for membership and once I get it I will post the profile there.

Cheers



«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Business Rules
« Reply #14 on: April 12, 2006, 06:15:36 pm »
Excellent point, and I concur on all counts!

My experience is that the permission will come through quickly. I'll try to remember to check for this, but I'd certainly welcome it if you want to zip it up and fire it over.

David
No, you can't have it!