Skip to content

Commit

Permalink
more
Browse files Browse the repository at this point in the history
  • Loading branch information
yegor256 committed Nov 15, 2023
1 parent c79e32d commit e47e670
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 5 deletions.
33 changes: 32 additions & 1 deletion 09-CAMC-and-NHD/09-CAMC-and-NHD.tex
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,37 @@

\plush{\sqmTitlePage{9}}

\pitch{
\pptBanner{Rational Unified Process (RUP)}
\pptPic{.7}{rup.png}}

\pptBanner{Decoupling via Interfaces (in Java)}
\begin{pptWide}{2}
{\small\begin{ffcode}
interface Shape
double area();

class Circle implements Shape
int r;
@Override
double area()
return r * r * 3.14d;

void main(Shape s)
double a = s.area();
\end{ffcode}
}
\par\columnbreak\par
\begin{tikzpicture}[graph]
\node[rectangle] (shape) {Shape};
\node[rectangle, below=3em of shape] (circle) {Circle};
\node[rectangle, left=3em of shape] (main) {main()};
\draw (main) edge[-triangle 45] (shape);
\draw (circle) edge[-open triangle 60] (shape);
\end{tikzpicture}
\end{pptWide}
\plush{}

\pitch{\pptBanner{CAMC}\pptQuote{jagdish-bansiya.jpg}{Cohesion Among Methods of Classes (CAMC) evaluates the relatedness of methods in the interface of a class using the parameter lists defined for the methods. It can be applied earlier in the development than can traditional cohesiveness metrics because it relies only on method prototypes declared in a class.}{\textit{A Class Cohesion Metric for Object-Oriented Designs}, \emph{Jagdish Bansiya}, Letha Etzkorn, Carl Davis and Wei Li, Journal of Object-Oriented Programming, vol.~11, no.~8, 1999}}

\plush{\begin{pptWide}{2}
Expand Down Expand Up @@ -59,7 +90,7 @@
\begin{multicols}{2}
\begin{itemize}
\item ``interface'' in Java
\item ``protocol'' in Swift
\item ``protocol'' in Objective-C
\item ``interface'' in C\#
\item ``abstract class'' in C++
\item absent in Python
Expand Down
Binary file added 09-CAMC-and-NHD/rup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions sqm.sty
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@
\RequirePackage[nocn,novert]{ffcode}
\RequirePackage{to-be-determined}
\RequirePackage{tikz}
\usetikzlibrary{positioning,calc,arrows.meta}
\usetikzlibrary{positioning,calc,arrows,arrows.meta}
\RequirePackage{soul}
\renewcommand\emph[1]{\ul{#1}}
\tikzstyle{graph} = [
node distance=0,
every node/.style={draw=black,circle,minimum width=2.2em,thick},
every edge/.append style={draw=black,thick,-{Latex[length=2.5mm,width=2mm]},every node/.style={above}},
every loop/.append style={draw=black,thick,-{Latex[length=2.5mm,width=2mm]},every node/.style={above}},
every node/.style={draw=black,circle,minimum width=2.2em,line width=.08em,outer sep=.2em,font={\ttfamily}},
every edge/.append style={draw=black,line width=.08em,-{Latex[length=2.5mm,width=2mm]},every node/.style={above}},
every loop/.append style={draw=black,line width=.08em,-{Latex[length=2.5mm,width=2mm]},every node/.style={above}},
]

\newcommand\sqmDisclaimer{{%
Expand Down

0 comments on commit e47e670

Please sign in to comment.