diff --git a/chapters/3.application-design/3.4.use-cases.tex b/chapters/3.application-design/3.4.use-cases.tex index 6935128..824bb70 100644 --- a/chapters/3.application-design/3.4.use-cases.tex +++ b/chapters/3.application-design/3.4.use-cases.tex @@ -68,6 +68,13 @@ {Σενάριο χρήσης 1 - Εναλλακτική ροή 3} {3-4-use-case-sign-up-alternate-flow-3} +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-sign-up-sequence-diagram} + \caption{Σενάριο χρήσης 1 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-sign-up-base-flow-sequence-diagram} +\end{figure} + % ===== ===== % Use case 2 % ===== ===== @@ -121,6 +128,20 @@ {Σενάριο χρήσης 2 - Εναλλακτική ροή 2} {3-4-use-case-create-topic-alternate-flow-2} +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-create-topic-sequence-diagram} + \caption{Σενάριο χρήσης 2 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-create-topic-base-flow-sequence-diagram} +\end{figure} + +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-create-topic-alternate-flow-1-sequence-diagram} + \caption{Σενάριο χρήσης 2 - Διάγραμμα εναλλακτικής ροής 1} + \label{figure:3-4-use-case-create-topic-alternate-flow-1-sequence-diagram} +\end{figure} + % ===== ===== % Use case 3 % ===== ===== @@ -146,6 +167,34 @@ {Σενάριο χρήσης 3 - Βασική ροή} {3-4-use-case-fetch-topic-base-flow} +\useCaseAlternateFlowTable +{1} +{Το θέμα περιέχει ψηφοφορία.} +{Εφόσον το θέμα που ανακτήθηκε στη γραμμή 1 της Βασικής Ροής περιέχει ψηφοφορία ανακτώνται οι πληροφορίες της.} +{ + 1 & - & Το σύστημα ανακτά τα μηνύματα του θέματος αντιγράφοντας τις προσωπικές βάσεις OrbitDb των συγγραφέων. \\ [0.5ex] + 2 & - & Το σύστημα ανακτά την ψηφοφορία από το blockchain. \\ [0.5ex] + 3 & - & Το σύστημα ανακτά τις πληροφορίες της ψηφοφορίας αντιγράφοντας την προσωπική βάση OrbitDb του συγγραφέα. \\ [0.5ex] + 4 & - & Το σύστημα επιβεβαιώνει τις πληροφορίες της ψηφοφορίας με βάση το hash που έχει ανακτηθεί από το blockchain. \\ [0.5ex] +} +{Το σενάριο χρήσης τερματίζεται.} +{Σενάριο χρήσης 3 - Εναλλακτική ροή 1} +{3-4-use-case-fetch-topic-alternate-flow-1} + +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-fetch-topic-sequence-diagram} + \caption{Σενάριο χρήσης 3 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-fetch-topic-base-flow-sequence-diagram} +\end{figure} + +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-fetch-topic-alternate-flow-1-sequence-diagram} + \caption{Σενάριο χρήσης 3 - Διάγραμμα εναλλακτικής ροής 1} + \label{figure:3-4-use-case-fetch-topic-alternate-flow-1-sequence-diagram} +\end{figure} + % ===== ===== % Use case 4 % ===== ===== @@ -184,6 +233,13 @@ {Σενάριο χρήσης 4 - Εναλλακτική ροή 1} {3-4-use-case-create-post-alternate-flow-1} +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-create-post-sequence-diagram} + \caption{Σενάριο χρήσης 4 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-create-post-base-flow-sequence-diagram} +\end{figure} + % ===== ===== % Use case 5 % ===== ===== @@ -207,6 +263,13 @@ {Σενάριο χρήσης 5 - Βασική ροή} {3-4-use-case-vote-in-poll-base-flow} +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-vote-in-poll-sequence-diagram} + \caption{Σενάριο χρήσης 5 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-vote-in-poll-base-flow-sequence-diagram} +\end{figure} + % ===== ===== % Use case 6 % ===== ===== @@ -228,4 +291,11 @@ } {Το σύστημα ανανεώνει τις ψήφους του μηνύματος.} {Σενάριο χρήσης 6 - Βασική ροή} -{3-4-3-4-use-case-vote-post-base-flow} +{3-4-use-case-vote-post-base-flow} + +\begin{figure}[H] + \centering + \input{tikz/chapter-3/3-4-use-case-vote-post-sequence-diagram} + \caption{Σενάριο χρήσης 6 - Διάγραμμα βασικής ροής} + \label{figure:3-4-use-case-vote-post-base-flow-sequence-diagram} +\end{figure} diff --git a/packages.tex b/packages.tex index d7a03a5..ffa4d1e 100644 --- a/packages.tex +++ b/packages.tex @@ -25,6 +25,9 @@ \usepackage{tabularx} % Support for break lines inside table cells \usepackage{booktabs} % Useful table styling commands +% --- TikZ and UML diagrams +\usepackage{pgf-umlsd} + % --- Bibliography --- \usepackage[sorting=none]{biblatex} % Make sure to have biber as default bibliography tool (e.g. in Texstudio's build configuration) diff --git a/thesis.pdf b/thesis.pdf index 25671b0..7113f15 100644 Binary files a/thesis.pdf and b/thesis.pdf differ diff --git a/tikz/chapter-3/3-4-use-case-create-post-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-create-post-sequence-diagram.tex new file mode 100644 index 0000000..8b21908 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-create-post-sequence-diagram.tex @@ -0,0 +1,19 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[3]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Create post}{concordia}{Post creation form} + \end{call} + + \begin{call}{actor}{Submit}{concordia}{Updated topic page} + + \begin{call}{concordia}{Create post}{eth}{New post ID} + \end{call} + + \begin{call}{concordia}{Save post information}{orbit}{} + \end{call} + + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-create-topic-alternate-flow-1-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-create-topic-alternate-flow-1-sequence-diagram.tex new file mode 100644 index 0000000..11dfa45 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-create-topic-alternate-flow-1-sequence-diagram.tex @@ -0,0 +1,28 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[4]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Create topic}{concordia}{Topic creation form} + \end{call} + + \begin{call}{actor}{Add poll}{concordia}{Poll creation form} + \end{call} + + \begin{call}{actor}{Submit}{concordia}{New topic-poll page} + + \begin{call}{concordia}{Create topic}{eth}{New topic ID} + \end{call} + + \begin{call}{concordia}{Add poll to topic}{eth}{} + \end{call} + + \begin{call}{concordia}{Save topic information}{orbit}{} + \end{call} + + \begin{call}{concordia}{Save poll information}{orbit}{} + \end{call} + + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-create-topic-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-create-topic-sequence-diagram.tex new file mode 100644 index 0000000..9a4a269 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-create-topic-sequence-diagram.tex @@ -0,0 +1,19 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[4]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Create topic}{concordia}{Topic creation form} + \end{call} + + \begin{call}{actor}{Submit}{concordia}{New topic page} + + \begin{call}{concordia}{Create topic}{eth}{New topic ID} + \end{call} + + \begin{call}{concordia}{Save topic information}{orbit}{} + \end{call} + + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-fetch-topic-alternate-flow-1-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-fetch-topic-alternate-flow-1-sequence-diagram.tex new file mode 100644 index 0000000..e7b0aef --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-fetch-topic-alternate-flow-1-sequence-diagram.tex @@ -0,0 +1,41 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[2]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Fetch topic}{concordia}{Topic} + + \begin{call}{concordia}{Get topic}{eth}{Topic} + \end{call} + + \begin{call}{concordia}{Get poll}{eth}{Poll} + \end{call} + + \begin{call}{concordia}{Get topic post IDs}{eth}{Post IDs} + \end{call} + + \begin{call}{concordia}{Get posts loop}{concordia}{Posts} + + \begin{call}{concordia}{Get post}{eth}{Post} + \end{call} + + \end{call} + + \begin{call}{concordia}{Retrieve topic information}{orbit}{} + \end{call} + + \begin{call}{concordia}{Retrieve poll information}{orbit}{} + \end{call} + + \begin{call}{concordia}{Validate poll information}{concordia}{} + \end{call} + + \begin{call}{concordia}{Retrieve posts information loop}{concordia}{Posts information} + + \begin{call}{concordia}{Retrieve post information}{orbit}{} + \end{call} + + \end{call} + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-fetch-topic-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-fetch-topic-sequence-diagram.tex new file mode 100644 index 0000000..15f0b95 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-fetch-topic-sequence-diagram.tex @@ -0,0 +1,32 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[2]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Fetch topic}{concordia}{Topic} + + \begin{call}{concordia}{Get topic}{eth}{Topic} + \end{call} + + \begin{call}{concordia}{Get topic post IDs}{eth}{Post IDs} + \end{call} + + \begin{call}{concordia}{Get posts loop}{concordia}{Posts} + + \begin{call}{concordia}{Get post}{eth}{Post} + \end{call} + + \end{call} + + \begin{call}{concordia}{Retrieve topic information}{orbit}{} + \end{call} + + \begin{call}{concordia}{Retrieve posts information loop}{concordia}{Posts information} + + \begin{call}{concordia}{Retrieve post information}{orbit}{} + \end{call} + + \end{call} + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-sign-up-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-sign-up-sequence-diagram.tex new file mode 100644 index 0000000..0220bf1 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-sign-up-sequence-diagram.tex @@ -0,0 +1,26 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[4]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + \newinst[1]{orbit}{:OrbitDb}{} + + \begin{call}{actor}{Sign up}{concordia}{Sign up form} + \end{call} + + \begin{call}{actor}{Submit}{concordia}{Personal information form} + + \begin{call}{concordia}{Create user}{eth}{New user ID} + \end{call} + + \begin{call}{concordia}{Create databases}{orbit}{} + \end{call} + + \end{call} + + \begin{call}{actor}{Submit}{concordia}{Home page} + + \begin{call}{concordia}{Save personal information}{orbit}{} + \end{call} + + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-vote-in-poll-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-vote-in-poll-sequence-diagram.tex new file mode 100644 index 0000000..2fb9620 --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-vote-in-poll-sequence-diagram.tex @@ -0,0 +1,12 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[3]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + + \begin{call}{actor}{Submit poll vote}{concordia}{Updated topic page} + + \begin{call}{concordia}{Add poll vote}{eth}{} + \end{call} + + \end{call} +\end{sequencediagram} diff --git a/tikz/chapter-3/3-4-use-case-vote-post-sequence-diagram.tex b/tikz/chapter-3/3-4-use-case-vote-post-sequence-diagram.tex new file mode 100644 index 0000000..404c21b --- /dev/null +++ b/tikz/chapter-3/3-4-use-case-vote-post-sequence-diagram.tex @@ -0,0 +1,12 @@ +\begin{sequencediagram} + \newthread{actor}{Actor}{} + \newinst[3]{concordia}{:Concordia}{} + \newinst[2]{eth}{:Ethereum}{} + + \begin{call}{actor}{Submit post vote}{concordia}{Updated topic page} + + \begin{call}{concordia}{Add post vote}{eth}{} + \end{call} + + \end{call} +\end{sequencediagram}