上大学Finding Participating Objects in Use Cases SHANGHAI JIAO TONG UNIVERSITY Pick a use case and look at its flow of events Find terms that developers or users need to clarify in order to understand the flow of events Look for recurring nouns (e.g.,Incident), Identify real world entities that the system needs to keep track of (e.g.,FieldOfficer,Dispatcher,Resource), Identify real world procedures that the system needs to keep track of (e.g.,EmergencyOperationsPlan), Identify data sources or sinks (e.g.,Printer) Identify interface artifacts (e.g.,PoliceStation)le.g.,telecomm link?] Be prepared that some objects are still missing and need to be found: Model the flow of events with a sequence diagram Always use the user's terms Software Engineering
Software Engineering Finding Participating Objects in Use Cases Pick a use case and look at its flow of events • Find terms that developers or users need to clarify in order to understand the flow of events • Look for recurring nouns (e.g., Incident), • Identify real world entities that the system needs to keep track of (e.g., FieldOfficer, Dispatcher, Resource), • Identify real world procedures that the system needs to keep track of (e.g., EmergencyOperationsPlan), • Identify data sources or sinks (e.g., Printer) • Identify interface artifacts (e.g., PoliceStation) [e.g., telecomm link?] Be prepared that some objects are still missing and need to be found: • Model the flow of events with a sequence diagram Always use the user’s terms
上游充通大¥ SHANGHAI JIAO TONG UNIVERSITY Example:Flow of events The customer enters a store with the intention of buying a toy for his child with the age of n. Help must be available within less than one minute. The store owner gives advice to the customer.The advice depends on the age range of the child and the attributes of the toy. The customer selects a dangerous toy which is kind of unsuitable for the child. The store owner recommends a more yellow doll Software Engineering
Software Engineering Example: Flow of events The customer enters a store with the intention of buying a toy for his child with the age of n. Help must be available within less than one minute. The store owner gives advice to the customer. The advice depends on the age range of the child and the attributes of the toy. The customer selects a dangerous toy which is kind of unsuitable for the child. The store owner recommends a more yellow doll
上游充通大学 Mapping parts of speech to object model SHANGHAI JIAO TONG UNIVERSITY components [Abbott,1983] Part of speech Model component? Example Proper noun Jim Smith Improper noun Toy,doll Doing verb ? Buy,recommend being verb ? is-a(kind-of) having verb ? has an ? modal verb must be ? adjective 3 years old ? transitive verb enter intransitive verb depends on Software Engineering
Software Engineering Mapping parts of speech to object model components [Abbott, 1983] Part of speech Model component? * Example Proper noun Jim Smith Improper noun Toy, doll Doing verb Buy, recommend being verb is-a (kind-of) having verb has an modal verb must be adjective 3 years old transitive verb enter intransitive verb depends on ? ? ? ? ? ? ? ? ?
上游充通大学 Mapping parts of speech to object model SHANGHAI JIAO TONG UNIVERSITY components [Abbott,1983] Part of speech Model component? Example Proper noun Jim Smith Improper noun Toy,doll Doing verb ? Buy,recommend being verb ? is-a(kind-of) having verb ? has an ? modal verb must be ? adjective 3 years old ? transitive verb enter intransitive verb depends on *(aggregationlattributelclassconstraintlinheritancelmethodmethod(event)lobject?)-RIL Software Engineering
Software Engineering Mapping parts of speech to object model components [Abbott, 1983] Part of speech Model component? * Example Proper noun Jim Smith Improper noun Toy, doll Doing verb Buy, recommend being verb is-a (kind-of) having verb has an modal verb must be adjective 3 years old transitive verb enter intransitive verb depends on ? ? ? ? ? ? ? ? ? * {aggregation|attribute|class|constraint|inheritance|method|method(event)|object?} - RJL
上游充通大学 Mapping parts of speech to object model SHANGHAI JIAO TONG UNIVERSITY components [Abbott,1983] Part of speech Model component Example Proper noun object Jim Smith Improper noun class Toy,doll Doing verb method Buy,recommend being verb inheritance is-a (kind-of) having verb aggregation has an modal verb constraint must be adjective attribute 3 years old transitive verb method enter intransitive verb method (event) depends on Software Engineering
Software Engineering Mapping parts of speech to object model components [Abbott, 1983] Part of speech Model component Example Proper noun object Jim Smith Improper noun class Toy, doll Doing verb method Buy, recommend being verb inheritance is-a (kind-of) having verb aggregation has an modal verb constraint must be adjective attribute 3 years old transitive verb method enter intransitive verb method (event) depends on