Book a Demo

Author Topic: AssociationClass & Operations?  (Read 5722 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
AssociationClass & Operations?
« on: August 29, 2005, 07:51:34 pm »
Following on from Jim Shaw's question about Associations, it got me wondering...

Can an AssociationClass have Operations (methods)?

I've never really thought about it much, but from memory, all the ones I've created had only Attributes (or at most Setters and Getters for equivalent Properties).

Thoughts anyone?

Paolo
« Last Edit: August 29, 2005, 07:53:58 pm by PaoloFCantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

thomaskilian

  • Guest
Re: AssociationClass & Operations?
« Reply #1 on: August 30, 2005, 06:21:31 am »
Triggers in an according database table?

jeshaw2

  • EA User
  • **
  • Posts: 701
  • Karma: +0/-0
  • I'm a Singleton, what pattern are you?
    • View Profile
Re: AssociationClass & Operations?
« Reply #2 on: August 30, 2005, 12:39:51 pm »
I think from 7.3.4 and 7.3.5 of the UJML spec, it is entirely possible for an AssociationClass to have a behavior.


For example, such an association, having a temporal constraint, could notify other objects when the constraint is satisfied or dissatisfied.  When a part-time employee comes into his scheduled work period, the association could notify a combo-box listing currently active employees.
Verbal Use Cases aren't worth the paper they are written upon.