Team_C

Sws

Task

Given a state of the PIRRO system, specify what actions can a user perform.

Approach

  • We group the actions according to the component that handles them.
  • We mainly focus on the Compositor actions.
  • The state is specified by a series of operations that query the state and return the information.

Compositor user actions

We group the actions in two categories:

Versioning related

Workspace related

Other Tools

Formal Specification of user interface

Helper definitions

 	\begin{tabular}{c l} 		$W$ & the current user working set \\ 		$\mathcal{B}$ & the set of all defined branches \\                           $ClipBoard$ & temporary storage of compositions outside the workspace \\ 	\end{tabular}

$ \text{isConsistent} (W) = \forall C \in W . \forall (i,p_i,r_i),(j,p_j,r_j) \in C . \bigl( i = j \Rightarrow p_i = p_j \wedge r_i = r_j \bigr) . $

$ \text{noConflicts} (C,C') = \forall (i,p_i,r_i) \in C . \forall (j,p_j,r_j) \in C' . \bigl( i = j \Rightarrow p_i = p_j \wedge r_i = r_j \bigr) . $

User events

Versioning Operations

Get all branches

    • INPUT GetAllBranches?
    • PRE -
    • ACTION query versioning component for all the defined branches; return a sequence of all branches; DISPLAY(TXT-ALL-BRANCHES,$\mathcal{B}$)
    • POST -

Browse specific branch

    • INPUT BrowseBranch? $(B)$
    • PRE $B \in \mathcal{B}$
    • ACTION query versioning component for the specified branch; DISPLAY(COMPOSITOR-VIEWPORT,$B$)
    • POST -

Commit to branch

    • INPUT Commit
    • PRE workspaceBranch$(W) = B\ \wedge$ isConsistent$(W) $ \\$\wedge\ \forall C \in W $ version$(C) = $ currentVersion$(C)$
    • ACTION Versioning::Commit$(W,B)$
    • POST -

Update branch

    • INPUT Update
    • PRE workspaceBranch$(W) = B$
    • ACTION $W' = $ Versioning::Update$(W,B) $
    • POST $W = W'$

Merge with branch

    • INPUT Merge($B_t$)
    • PRE workspaceBranch$(W) = B_s\ \wedge$ isConsistent$(W) $  \\$\wedge\ \forall C \in W $ version$(C) = $ currentVersion$(C)$
    • ACTION Versioning::Merge$(B_s,B_t), W' = $ Versioning::Checkout$(B_t,LATEST)$
    • POST $W = W'$

Revert to version

    • INPUT Revert$(vers)$
    • PRE workspaceBranch$(W) = B\ \wedge$ currentVersion$(B) \geq vers$
    • ACTION $W' = $ Versioning::Checkout$(B,vers)$
    • POST $W = W'$

Branch

    • INPUT Branch($B_n$)
    • PRE workspaceBranch$(W) = B_s$
    • ACTION Versioning::Branch$(B_s,B_n)$, $W' = $ Versioning::Checkout$(B_n,LATEST)$
    • POST $W = W'$

Compositor operations

Add piece

    • INPUT Add(P)
    • PRE -
    • ACTION -
    • POST $ W'= W \cup \{P\} $

Move composition

    • INPUT Move$(\Delta)$
    • PRE selected$(W) = \{C\}\ \wedge$ position$(C) = pos$
    • ACTION Compositor::Move$(C,\Delta)$
    • POST position$(C) = pos + \Delta $

Rotate composition

    • INPUT Rotate$(\theta)$
    • PRE selected$(W) = \{C\}\ \wedge$ rotation$(C) = \alpha $
    • ACTION Compositor::Rotate$(C,\theta)$
    • POST rotation$(C) = \theta + \alpha $

Remove composition

    • INPUT Remove
    • PRE selected$(W) = \{C\}$
    • ACTION Compositor::Remove$(C,W)$
    • POST $C \notin W\ \wedge$ selected$(W) = \emptyset$

Remove member

    • INPUT RemoveMember? (P)
    • PRE selected$(W) = \{C\} \wedge P \in C $
    • ACTION Compositor::RemoveMember$(P,C)$
    • POST $C \notin W\ \wedge (C-{P}) \in W \wedge $ selected$(W) = \emptyset$

Combine two compositions

    • INPUT Combine
    • PRE selected$(W) = \{C_1,C_2\}\ \wedge$ noConflicts$(C1,C2)$
    • ACTION $C = $ Compositor::Combine$(C_1,C_2)$
    • POST $C_1 \notin W\ \wedge\ C_2 \notin W\ \wedge C \in W\ \wedge$ selected$(W) = {C}$

Extract a piece

    • INPUT Extract(P)
    • PRE selected$(W) = \{C\}$
    • ACTION $C' = $ Compositor::Extract$(C,P)$
    • POST $W' = (W-C) \cup {P} \cup C' \wedge $ selected$(W') = {P}$

Pan viewport

    • INPUT Pan$(\delta)$
    • PRE position$(VIEWPORT) = pos$
    • ACTION Compositor::Pan$(\delta)$
    • POST position$(VIEWPORT) = pos + \delta$

Zoom viewport

    • INPUT Zoom$(\delta)$
    • PRE zoom$(VIEWPORT) = z$
    • ACTION Compositor::Zoom$(\delta)$
    • POST zoom$(VIEWPORT) = z + \delta$

After user login

    • INPUT LoginCompleted? $(U)$
    • PRE $B = $ getGroupBranch$(U)\ \wedge$ position$(VIEWPORT) = (0,0) \wedge$ lastPosition$(U) = pos$
    • ACTION $W' = $ Versioning::Get$(B,LATEST)$, Compositor::Pan$(pos)$
    • POST $W = W' \wedge $ position$(VIEWPORT) = pos$

Annotate

    • INPUT Annotate(M)
    • PRE selected$(W) = \{C\}$
    • ACTION Compositor::Annotate$(C,M)$
    • POST -

Other Tools

Select composition

    • INPUT Select$(C)$
    • PRE $C \in W$
    • ACTION -
    • POST selected$(W) =\{C\} \cup$ selected$(W)$

UnSelect? composition

    • INPUT UnSelect? $(C)$
    • PRE $C \in W \wedge S = selected(W) $
    • ACTION -
    • POST selected$(W) = S-{C} $

Cut composition

    • INPUT Cut
    • PRE $ S = selected(W) \wedge S \neq \emptyset $
    • ACTION -
    • POST selected$(W') = \emptyset \wedge $ ClipBoard? $ = S \wedge W'= W - S $

Paste composition

    • INPUT Paste
    • PRE $ S = $ ClipBoard? $ \wedge S \neq \emptyset $
    • ACTION -
    • POST selected$(W') = S \wedge$ ClipBoard? $=\emptyset \wedge W'= W \cup S $

Topic attachments
I Attachment Action Size Date Who Comment
pdfpdf sws15.pdf manage 31.1 K 26 Oct 2009 - 17:25 TamarChristina