% The name of Kieker, just for the case that the design of this should change.
\newcommand{\Kieker}{\textsf{Kieker}}

% The current version-string.
\newcommand{\version}{1.10} % will be set automatically by ant 'release' target 

% The single parts of Kieker and some files.
\newcommand{\KiekerMonitoringPart}{\textsf{Kieker.\-Monitoring}}
\newcommand{\KiekerAnalysisPart}{\textsf{Kieker.\-Analysis}}
\newcommand{\KiekerTraceAnalysis}{\textsf{Kieker.Trace\-Analysis}}
% \newcommand{\analysisJar}{kieker-analysis-\version.jar}
\newcommand{\mainJar}{kieker-1.10.jar} % will be set automatically by ant 'release' target
\newcommand{\mainJarEMF}{kieker-1.10\_emf.jar} % will be set automatically by ant 'release' target
\newcommand{\mainJarWeaver}{kieker-1.10\_aspectj.jar} % will be set automatically by ant 'release' target
% \newcommand{\monitoringJar}{kieker-monitoring-\version.jar}
% \newcommand{\commonJar}{kieker-common-\version.jar}
% \newcommand{\toolsJar}{kieker-tools-\version.jar}
\newcommand{\commonsLoggingJar}{commons-logging-1.1.2.jar}
\newcommand{\aspectJWeaverJar}{aspectjweaver-1.8.2.jar}
\newcommand{\monitoringPropertiesFile}{kieker.\-monitoring.\-pro\-per\-ties}
\newcommand{\analysisPropertiesFile}{kieker.analysis.properties}
\newcommand{\sigarJar}{sigar-1.6.4.jar}

\newcommand{\aopConfigFile}{aop.xml}
\newcommand{\binaryFileForDownload}{kieker-\version{}\_bina\-ries.zip}
\newcommand{\kiekerMonitoringProperties}{kieker.monitoring.pro\-perties}
\newcommand{\kiekerExampleMonitoringProperties}{kieker.monitoring.ex\-am\-ple.pro\-perties}

%%
\newcommand{\aspectJURL}{www.eclipse.org/aspectj/}

% Some directories for the examples
\newcommand{\userGuideDir}{doc/userguide}
\newcommand{\exampleDir}{examples/userguide}
\newcommand{\exampleDirWin}{examples\textbackslash{}userguide}
\newcommand{\exampleDirRelativePath}{../../\exampleDir}
\newcommand{\plainBookstoreApplicationDir}{\exampleDirRelativePath/ch2--bookstore-application}
\newcommand{\plainBookstoreApplicationDirDistro}{\exampleDir/ch2--bookstore-application}
\newcommand{\manualInstrumentedBookstoreApplicationDir}{\exampleDirRelativePath/ch2--manual-instrumentation}
\newcommand{\manualInstrumentedBookstoreApplicationDirDistro}{\exampleDir/ch2--manual-instrumentation}
\newcommand{\customComponentsBookstoreApplicationDir}{\exampleDirRelativePath/ch3-4--custom-components}
\newcommand{\customComponentsBookstoreApplicationDirDistro}{\exampleDir/ch3-4--custom-components}
\newcommand{\aspectJBookstoreApplicationDir}{\exampleDirRelativePath/ch5--trace-monitoring-aspectj}
\newcommand{\aspectJBookstoreApplicationDirDistro}{\exampleDir/ch5--trace-monitoring-aspectj}
\newcommand{\aspectJBookstoreApplicationDirDistroWin}{\exampleDirWin\textbackslash{}ch5--trace-monitoring-aspectj}
\newcommand{\kiekerSrcDir}{../../src/}

\newcommand{\distributedTestdataDir}{\aspectJBookstoreApplicationDir/testdata/kieker-20100830-082225522-UTC}
\newcommand{\distributedTestdataDirDistro}{\aspectJBookstoreApplicationDirDistro/testdata/kieker-20100830-082225522-UTC}
\newcommand{\distributedTestdataDirDistroWin}{..\textbackslash{}\aspectJBookstoreApplicationDirDistroWin\textbackslash{}testdata\textbackslash{}kieker-20100830-082225522-UTC}

\newcommand{\JMSBookstoreApplicationDir}{\exampleDirRelativePath/appendix-JMS}
\newcommand{\JMSBookstoreApplicationDirDistro}{\exampleDir/appendix-JMS}

\newcommand{\SigarExampleDir}{\exampleDirRelativePath/appendix-Sigar}
\newcommand{\SigarExampleDirDistro}{\exampleDir/appendix-Sigar}

\newcommand{\JavaEEServletExampleName}{JavaEEServletContainerExample}
\newcommand{\JavaEEServletExampleDir}{../../examples/\JavaEEServletExampleName}
\newcommand{\JavaEEServletExampleDistro}{examples/\JavaEEServletExampleName}


% The complete url where to find Kieker.
\newcommand{\KiekerURL}{\url{http://kieker-monitoring.net}} 
% \newcommand{\KiekerDownloadURL}{\url{http://sourceforge.net/projects/kieker/files}}
\newcommand{\KiekerDownloadURL}{\url{http://kieker-monitoring.net/download/}}

% This is how we call the kieker directory.
\newcommand{\KiekerDir}{kieker-\version{}}%{$<$KIEKER-DIR$>$}

% These commands are necessary to mark classes, methods and files within the document.
\newcommand{\object}[1]{\texttt{#1}}
\newcommand{\class}[1]{\texttt{#1}}
\newcommand{\method}[1]{\textit{#1}}
\newcommand{\dir}[1]{\texttt{#1}}
\newcommand{\file}[1]{\texttt{#1}}

% This command formats the "new" files within a directory tree to get the users attention.
\newcommand{\newFilesDirTreeFormat}{\color{blue}}
\newcommand{\DirInDirTree}[1]{\textbf{#1}}
\newcommand{\newFileDirInDirTree}[1]{\colorbox{gray}{\color{white}#1}}


% These commands are for notifying the reader about something important.
\newcommand{\marginbox}[1]{\todo[noline]{#1}}
\newcommand{\notify}{\marginbox{\huge{\rightpointleft}}}
\newcommand{\warning}{\marginbox{\huge{\Stopsign}}}

% TODO command for our document
\newcommand{\TODO}[1]{\todo[inline,color=green!40]{TODO: #1}}

\makeatletter
\newcommand{\SYMBOLBOX}[2]{%
\begin{lrbox}{\@tempboxa}
\begin{minipage}[t]{0.1\textwidth}\vspace{1pt}
\begin{center}
\huge#1
\end{center}
\end{minipage}
\begin{minipage}[t]{0.8\textwidth}
#2%
\end{minipage}
\end{lrbox}
\todo[inline,bordercolor=black]{\usebox{\@tempboxa}}
}
\makeatother

\newcommand{\NOTIFYBOX}[1]{\SYMBOLBOX{\leftpointright}{#1}}
\newcommand{\WARNBOX}[1]{\SYMBOLBOX{\Stopsign}{#1}}

% This color will be used as backgroundcolor for the listings.
\definecolor{verylightgray}{gray}{.95}

% workaround for the listing's commentstyle
\newcommand{\textrmit}[1]{\textit{\textrm{#1}}}

% The following commands set the listings for the different (programming) languages correctly.
% For the first they use all nearly the same settings.
\newcommand{\setListing}[4]{
\lstset{    
numbers=#2,
basicstyle=#3,       	% the size of the fonts that are used for the code
keywordstyle=\bfseries,%
commentstyle={\textrmit},
showspaces=false,               % show spaces adding particular underscores
showstringspaces=false,         % underline spaces within strings
showtabs=false,                 % show tabs within strings adding particular underscores
%frame=shadowbox,	                % adds a frame around the code
% frame=lrtb,
rulesepcolor=\color{black},
linewidth=1\columnwidth,
columns=[c]flexible, % default is [c]fixed
% xleftmargin=1cm,
tabsize=2,	                % sets default tabsize to 2 spaces
captionpos=b,                   % sets the caption-position to bottom
breaklines=true,                % sets automatic line breaking
breakatwhitespace=false,        % sets if automatic breaks should only happen at whitespace
title=\lstname,                 % show the filename of files included with \lstinputlisting; also try caption instead of title
escapechar={#4},
backgroundcolor=\color{verylightgray},
style=#1, % they style may override one or more of the above settings
}
}

\lstdefinestyle{javaStyle}{
language=Java
}
\lstdefinestyle{bashStyle}{
language=Bash,
alsoletter={.,-,:}, % sonst auch 'java' in ClassName.java highlighted
morekeywords={java,javac,-classpath,-d,-jar,-javaagent:,copy,cp,dot,pic2plot,mkdir},
xleftmargin=3mm,
% showspaces=true
% emphstyle=\bfseries
}
\lstdefinestyle{xmlStyle}{
language=XML
}
\lstdefinestyle{PropertiesStyle}{
language=Bash,
xleftmargin=0mm
}
\lstdefinestyle{AntStyle}{
language=Ant,
xleftmargin=0mm
}
\lstdefinestyle{textStyle}{
language=,
xleftmargin=3mm
}

\newcommand{\UnixLikeSystem}{UNIX-like system}
\newcommand{\UnixLikeSystems}{UNIX-like systems}
\newcommand{\lstshellprompt}{$\triangleright$}
\newcommand{\lstHighlight}{\bfseries}
\newcommand{\setJavaCodeListing}{\setListing{eclipse-java}{left}{\sffamily\scriptsize}{\#}}
\newcommand{\setBashListing}{\setListing{bashStyle}{none}{\sffamily\footnotesize}{\#}}
\newcommand{\setPropertiesListing}{\setListing{PropertiesStyle}{none}{\sffamily\footnotesize}{}}
\newcommand{\setAntListing}{\setListing{AntStyle}{none}{\sffamily\footnotesize}{}}
\newcommand{\setTextListing}{\setListing{textStyle}{none}{\sffamily\scriptsize}{\$}}
\newcommand{\setXMLListing}{\setListing{xmlStyle}{left}{\sffamily\footnotesize}{}}

% This is the definition for the environment, that can be used for the background of the dirtrees.
\makeatletter\newenvironment{graybox}{%
   \begin{lrbox}{\@tempboxa}\begin{minipage}{0.965\columnwidth}}{\end{minipage}\end{lrbox}%
   \fcolorbox{white}{verylightgray}{\usebox{\@tempboxa}}
}\makeatother
