Presentation is loading. Please wait.

Presentation is loading. Please wait.

1SSPD Back to Jackson Consider how JSP views programming- –Describe structure I/O datastreams –Combine to produce a program structure –List operations.

Similar presentations


Presentation on theme: "1SSPD Back to Jackson Consider how JSP views programming- –Describe structure I/O datastreams –Combine to produce a program structure –List operations."— Presentation transcript:

1 1SSPD Back to Jackson Consider how JSP views programming- –Describe structure I/O datastreams –Combine to produce a program structure –List operations necessary to produce outputs; put each operation in place in program structure –Write the program text adding conditions as needed for controlling iterations & selections.

2 2SSPD Description First In JSP we first describe the subject matter of the problem. Then we turn attention to functional details Notice how technical detail is relegated.

3 3SSPD Abstraction in JSP Notice that the models we build (the data structure) are abstract descriptions of the real world. Whatever we include in the model can be used to produce system outputs. If it isn’t in the model, we can’t produce outputs in respect of it.

4 4SSPD JSD Same Foundations The subject matter in JSD is the real world, strongly ordered in time, outside the system Detailed function is production of system outputs Early development concerned with description of real world. Explicit consideration of function deferred.

5 5SSPD JSD JSD does not start from a given specification, nor does it decompose the system into sequential processes. Instead, development begins by creating a specification for the system, building it up from parts which are themselves sequential processes.

6 6SSPD Synthesis Therefore, we say that JSD is an activity of synthesis rather than decomposition. Used to develop systems in whose real world subject matter it is important to recognise occurrence of events within a time dimension.

7 7SSPD KEY IDEA It is claimed that easier to build more maintainable systems with JSD… …because the model of real world is a stable basis for development, being less likely to change than the functions built upon it.

8 8SSPD Model & Function In JSD we say that –the model implies function –i.e., we can specify any function in terms of members of the model. But in dysfunctional decomposition –the functions imply the model –i.e., we build a model in terms of required functions. This is inherently less flexible.

9 9SSPD

10 10SSPD Car Hire Revisited Let’s take a JSD view of the car hire problem. What is the real world of the car hire firm’s manager? The hiring and returning of vehicles. Thus we can model a vehicle

11 11SSPD Model of Vehicle VEHICLEPURCHASEDISPOSE WORKING LIFE HIRING HIRE RETURN *

12 12SSPD Model Implies Function The requirements for the system were (in order):- –Display number of hirings –Display average hiring duration Functional spec:- –Inspect model and count all hire events –Inspect model and evaluate period for each vehicle. –etc.

13 13SSPD Model Implies Function II Second requirement:- –Display longest hiring Functional spec:- –Inspect model, for each hiring evaluate duration –Calculate longest period

14 14SSPD Model Implies Function III The third requirement was:- –Display hirings < 1 week –Display hirings >= 1 week Functional spec:- –Inspect model. For each hiring, calculate duration. If 6 days or less put in one batch else put in the other.

15 15SSPD Model Implies Function IV The final requirement was:- –Allow the system to run at any time even when there are outstanding returns Functional specification:- –Inspect the model. For each of the above requirements, ignore any hiring which has a hire event but no matching return event.

16 16SSPD Immortality? Is a JSD system therefore immortal?

17 17SSPD Jackson System Development Introduction

18 18SSPD Warning! Some of the concepts in JSD are not easy to grasp at first

19 19SSPD Data Modelling Recall the data modelling relation: What does is-a- supplier-of mean? Discuss relation in terms of events.

20 20SSPD Understanding Relations Natural way to understand meaning of relation is to consider the real world events that affect it. Natural way to explain relation is in terms of those real world events. Event occurrence more basic than existence of a relation, thus that is where we will start our modelling.

21 21SSPD Events in JSD Events are: –atomic –instantaneous (both ideas are abstractions) Example: lending a book in a library system

22 22SSPD Event Attributes What, who, when, where etc… E.g., what was lent? When was it lent? Who lent it and to whom? etc. Gives us attributes such as: –date, –ISBN –Borrower id etc. etc. for the LEND event

23 23SSPD Define Event Classes LEND (Book_Id, Member_Id, Resvn_Id, Date) –A book, whose identifier is Book_Id, is lent to the member whose membership number us Member_Id; date is the date of removal of the book from the library's premises; Resvn_Id is the identifier of the relevant reservation if the cook is borrowed against a previous reservation.

24 24SSPD Importance of Events Initial description in terms of what happens in the real world Doing this begins to scope the eventual system Narrative gives link between the formal system spec we are building and the real world as understood by its users

25 25SSPD Objects & Event Orderings Picture is not complete. Events are participated in by real world objects (e.g. librarians and borrowers) We want to describe these objects that persist over time Analysing event traces helps us to identify the objects of interest

26 26SSPD Event Trace Analysis …Hire (Veh 3), Ret (Veh 2), Purchase (Veh 9), Hire (Veh 2), Hire (Veh 9), Hire (Veh 3), Ret (Veh 2), Ret (Veh 3), Ret (Veh 9)…Dispose (Veh 2), Hire (Veh 9), Ret (Veh 9), Dispose (Veh 9)… Analysis of this elicits time ordered event lists From this we derive candidate entities

27 27SSPD Entities Entity persists over time & participates in time ordered event traces. VEHICLEPURCHASEDISPOSE WORKING LIFE HIRING HIRE RETURN *

28 28SSPD Entity State Entities have state. State is recorded in entity’s fields (its instance variables) The entity state vector will store info about the entity’s event history E.g., Vehicle’s present state is ‘ON HIRE’, previous states include PURCHASE, HIRE, RETURN etc.

29 29SSPD Entity Attributes Attributes specified in terms of events E.g., HIRE_COUNT Also need to specify what attributes mean E.g., is HIRE_COUNT incremented upon hiring out, or upon return? What does attribute in-the-company mean?

30 30SSPD Definitions of Event –Something that happens to which the system has to respond…they cause a response in the system and an update to the information stored within the system [Sutcliffe] –An event in the world that forms the subject matter of the system and about which the system must produce or use information [Cameron]

31 31SSPD Definitions of Entity –Object of interest in the system which will undergo or cause change during system’s activity [Sutcliffe] –Object in the real world which participates in a time-ordered set of actions [Jackson] –Person, organisation or object that performs or suffers an interesting time sequence of actions [Cameron]

32 32SSPD Finding Events Events are atomic so reject those actions that are vague or that imply continuous actions Ignore (for the moment) any actions which imply output or responses in the real world. In the modelling phase events are those actions which respond in some way to input messages

33 33SSPD Guidelines –Decide on the external events which happen in the real world (e.g. customer orders goods) –Define how these events are communicated to the system as input (e.g. phone call is made) –Identify system inputs (action attributes) (e.g. a verbal order) –Define actions necessary to respond to messages in action attributes (e.g. despatch goods).

34 34SSPD Action Attributes Are answers to reasonable questions we might ask about an event –e.g., what was lent, who lent it etc.

35 35SSPD Finding Entities Start by analysing event traces (could be a lot of work here!) Look for real world objects with which the system must interact What is the main thing for which the system exists? Entities could be the nouns in event descriptions

36 36SSPD Try this Out Have a go at the Stitch in Time company.


Download ppt "1SSPD Back to Jackson Consider how JSP views programming- –Describe structure I/O datastreams –Combine to produce a program structure –List operations."

Similar presentations


Ads by Google