Re: basic q about sequence diagrams
From: Karl Hungus (nnnnndddddd_at_hotmail.com)
Date: 03/17/04
- Next message: Isaac Gouy: "Re: dynamic type checking - a pauline conversion?"
- Previous message: H. S. Lahman: "Re: is this a pattern?"
- In reply to: H. S. Lahman: "Re: basic q about sequence diagrams"
- Next in thread: H. S. Lahman: "Re: basic q about sequence diagrams"
- Reply: H. S. Lahman: "Re: basic q about sequence diagrams"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 16 Mar 2004 23:47:37 GMT
> > A user wants to know how many, so enquires from the system, by sending
> > a 'how many passengers do you have?' message to the car.
> >
> > so the answer is:
> > [system] ------getPassengers----->[car]
>
> Taken literally, that would not be a good practice. If all the client
> cares about is the number of passengers, it doesn't need the passengers
> themselves to determine that. It should ask for only what it does need,
> which is a count. Which is why giving [Car] a public responsibility for
> knowing how many passengers it has is reasonable.
in my original example, I just wanted to return a collection of passengers.
Assuming the system manipulates some attributes of the passengers outside
the context of car, I would think its ok (to do that in system). I agree the
car should keep count of its passengers.
Another more general question is, do you feel that sequence diagrams should
avoid method-like names in the messages? or is this another example of
conceptual vs specification vs implementation diagrams.
TIA
- Next message: Isaac Gouy: "Re: dynamic type checking - a pauline conversion?"
- Previous message: H. S. Lahman: "Re: is this a pattern?"
- In reply to: H. S. Lahman: "Re: basic q about sequence diagrams"
- Next in thread: H. S. Lahman: "Re: basic q about sequence diagrams"
- Reply: H. S. Lahman: "Re: basic q about sequence diagrams"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|