\section{lib/sparse/vector.h File Reference}
\label{vector_8h}\index{lib/sparse/vector.\-h@{lib/sparse/vector.\-h}}
{\ttfamily \#include $<$stdlib.\-h$>$}\\*
Include dependency graph for vector.\-h\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=141pt]{vector_8h__incl}
\end{center}
\end{figure}
This graph shows which files directly or indirectly include this file\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=141pt]{vector_8h__dep__incl}
\end{center}
\end{figure}
\subsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct {\bf vector\-\_\-struct}
\end{DoxyCompactItemize}
\subsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
typedef struct {\bf vector\-\_\-struct} $\ast$ {\bf Vector}
\item 
typedef {\bf Vector} {\bf String\-Vector}
\item 
typedef {\bf Vector} {\bf Integer\-Vector}
\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
{\bf Vector} {\bf Vector\-\_\-new} ({\bf int} maxlen, size\-\_\-t size\-\_\-of\-\_\-elem, void($\ast$deallocator)(void $\ast$v))
\item 
{\bf Vector} {\bf Vector\-\_\-add} ({\bf Vector} v, void $\ast$stuff)
\item 
{\bf Vector} {\bf Vector\-\_\-reset} ({\bf Vector} v, void $\ast$stuff, {\bf int} i)
\item 
void {\bf Vector\-\_\-delete} ({\bf Vector} v)
\item 
void $\ast$ {\bf Vector\-\_\-get} ({\bf Vector} v, {\bf int} i)
\item 
{\bf int} {\bf Vector\-\_\-get\-\_\-length} ({\bf Vector} v)
\item 
{\bf Vector} {\bf String\-Vector\-\_\-new} ({\bf int} len, {\bf int} delete\-\_\-element\-\_\-strings)
\item 
{\bf Vector} {\bf String\-Vector\-\_\-add} ({\bf Vector} v, char $\ast$i)
\item 
void {\bf String\-Vector\-\_\-delete} ({\bf Vector} v)
\item 
char $\ast$$\ast$ {\bf String\-Vector\-\_\-get} ({\bf Vector} v, {\bf int} i)
\item 
{\bf int} {\bf String\-Vector\-\_\-get\-\_\-length} ({\bf Vector} v)
\item 
{\bf Vector} {\bf String\-Vector\-\_\-reset} ({\bf Vector} v, char $\ast$content, {\bf int} pos)
\item 
void {\bf String\-Vector\-\_\-fprint} (F\-I\-L\-E $\ast$fp, {\bf String\-Vector} v)
\item 
void {\bf String\-Vector\-\_\-fprint1} (F\-I\-L\-E $\ast$fp, {\bf String\-Vector} v)
\item 
{\bf String\-Vector} {\bf String\-Vector\-\_\-part} ({\bf String\-Vector} v, {\bf int} n, {\bf int} $\ast$selected\-\_\-list)
\item 
{\bf Vector} {\bf Integer\-Vector\-\_\-new} ({\bf int} len)
\item 
{\bf Vector} {\bf Integer\-Vector\-\_\-add} ({\bf Vector} v, {\bf int} i)
\item 
void {\bf Integer\-Vector\-\_\-delete} ({\bf Vector} v)
\item 
{\bf int} $\ast$ {\bf Integer\-Vector\-\_\-get} ({\bf Vector} v, {\bf int} i)
\item 
{\bf int} {\bf Integer\-Vector\-\_\-get\-\_\-length} ({\bf Vector} v)
\item 
{\bf Vector} {\bf Integer\-Vector\-\_\-reset} ({\bf Vector} v, {\bf int} content, {\bf int} pos)
\end{DoxyCompactItemize}


\subsection{Typedef Documentation}
\index{vector.\-h@{vector.\-h}!Integer\-Vector@{Integer\-Vector}}
\index{Integer\-Vector@{Integer\-Vector}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector}]{\setlength{\rightskip}{0pt plus 5cm}typedef {\bf Vector} {\bf Integer\-Vector}}\label{vector_8h_aa42835cd243596e2e1f8937020534192}


Definition at line 56 of file vector.\-h.

\index{vector.\-h@{vector.\-h}!String\-Vector@{String\-Vector}}
\index{String\-Vector@{String\-Vector}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector}]{\setlength{\rightskip}{0pt plus 5cm}typedef {\bf Vector} {\bf String\-Vector}}\label{vector_8h_a1513b5ce88c34ec9b10d7f4936a104f9}


Definition at line 43 of file vector.\-h.

\index{vector.\-h@{vector.\-h}!Vector@{Vector}}
\index{Vector@{Vector}!vector.h@{vector.\-h}}
\subsubsection[{Vector}]{\setlength{\rightskip}{0pt plus 5cm}typedef struct {\bf vector\-\_\-struct}$\ast$ {\bf Vector}}\label{vector_8h_a7d86cfc0a808017228fa56cfc77fd76b}


Definition at line 24 of file vector.\-h.



\subsection{Function Documentation}
\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-add@{Integer\-Vector\-\_\-add}}
\index{Integer\-Vector\-\_\-add@{Integer\-Vector\-\_\-add}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-add}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Integer\-Vector\-\_\-add (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{{\bf int}}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_acae7c1352e0139d0cfbdce4374059098}


Definition at line 84 of file vector.\-c.



References Vector\-\_\-add().

\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-delete@{Integer\-Vector\-\_\-delete}}
\index{Integer\-Vector\-\_\-delete@{Integer\-Vector\-\_\-delete}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-delete}]{\setlength{\rightskip}{0pt plus 5cm}void Integer\-Vector\-\_\-delete (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_a0f904e0ba6dd452d6c6fa3ee3f59ae4e}


Definition at line 88 of file vector.\-c.



References Vector\-\_\-delete().

\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-get@{Integer\-Vector\-\_\-get}}
\index{Integer\-Vector\-\_\-get@{Integer\-Vector\-\_\-get}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-get}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int}$\ast$ Integer\-Vector\-\_\-get (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{{\bf int}}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_aba69c62e84548ce127066b22166188be}


Definition at line 92 of file vector.\-c.



References N\-U\-L\-L, and Vector\-\_\-get().

\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-get\-\_\-length@{Integer\-Vector\-\_\-get\-\_\-length}}
\index{Integer\-Vector\-\_\-get\-\_\-length@{Integer\-Vector\-\_\-get\-\_\-length}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-get\-\_\-length}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} Integer\-Vector\-\_\-get\-\_\-length (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_ab896b77b420fde39ce1fb0a4bcca8f2c}


Definition at line 99 of file vector.\-c.



References Vector\-\_\-get\-\_\-length().

\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-new@{Integer\-Vector\-\_\-new}}
\index{Integer\-Vector\-\_\-new@{Integer\-Vector\-\_\-new}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-new}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Integer\-Vector\-\_\-new (
\begin{DoxyParamCaption}
\item[{{\bf int}}]{len}
\end{DoxyParamCaption}
)}\label{vector_8h_ad533cba9a0c309b7446f23b4904ac030}


Definition at line 80 of file vector.\-c.



References intdealloactor(), and Vector\-\_\-new().

\index{vector.\-h@{vector.\-h}!Integer\-Vector\-\_\-reset@{Integer\-Vector\-\_\-reset}}
\index{Integer\-Vector\-\_\-reset@{Integer\-Vector\-\_\-reset}!vector.h@{vector.\-h}}
\subsubsection[{Integer\-Vector\-\_\-reset}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Integer\-Vector\-\_\-reset (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{{\bf int}}]{content, }
\item[{{\bf int}}]{pos}
\end{DoxyParamCaption}
)}\label{vector_8h_a45644d40d8b92d2857d6a703cf8d813e}


Definition at line 103 of file vector.\-c.



References Vector\-\_\-reset().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-add@{String\-Vector\-\_\-add}}
\index{String\-Vector\-\_\-add@{String\-Vector\-\_\-add}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-add}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} String\-Vector\-\_\-add (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{char $\ast$}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_a8e956a91a05028dae6c82181bcd6ff29}


Definition at line 130 of file vector.\-c.



References Vector\-\_\-add().



Referenced by String\-Vector\-\_\-part().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-delete@{String\-Vector\-\_\-delete}}
\index{String\-Vector\-\_\-delete@{String\-Vector\-\_\-delete}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-delete}]{\setlength{\rightskip}{0pt plus 5cm}void String\-Vector\-\_\-delete (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_a927522f75a1b8aec8418912b158fbe53}


Definition at line 134 of file vector.\-c.



References Vector\-\_\-delete().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-fprint@{String\-Vector\-\_\-fprint}}
\index{String\-Vector\-\_\-fprint@{String\-Vector\-\_\-fprint}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-fprint}]{\setlength{\rightskip}{0pt plus 5cm}void String\-Vector\-\_\-fprint (
\begin{DoxyParamCaption}
\item[{F\-I\-L\-E $\ast$}]{fp, }
\item[{{\bf String\-Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_a7fad51019986eaf7f4e975277e10dc21}


Definition at line 161 of file vector.\-c.



References String\-Vector\-\_\-get(), and String\-Vector\-\_\-get\-\_\-length().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-fprint1@{String\-Vector\-\_\-fprint1}}
\index{String\-Vector\-\_\-fprint1@{String\-Vector\-\_\-fprint1}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-fprint1}]{\setlength{\rightskip}{0pt plus 5cm}void String\-Vector\-\_\-fprint1 (
\begin{DoxyParamCaption}
\item[{F\-I\-L\-E $\ast$}]{fp, }
\item[{{\bf String\-Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_ae387f1f651038fb87cd0cc2eb642c296}


Definition at line 153 of file vector.\-c.



References String\-Vector\-\_\-get(), and String\-Vector\-\_\-get\-\_\-length().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-get@{String\-Vector\-\_\-get}}
\index{String\-Vector\-\_\-get@{String\-Vector\-\_\-get}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-get}]{\setlength{\rightskip}{0pt plus 5cm}char$\ast$$\ast$ String\-Vector\-\_\-get (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{{\bf int}}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_aee930be96099c8054725ba3542bfd240}


Definition at line 138 of file vector.\-c.



References N\-U\-L\-L, and Vector\-\_\-get().



Referenced by String\-Vector\-\_\-fprint(), String\-Vector\-\_\-fprint1(), and String\-Vector\-\_\-part().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-get\-\_\-length@{String\-Vector\-\_\-get\-\_\-length}}
\index{String\-Vector\-\_\-get\-\_\-length@{String\-Vector\-\_\-get\-\_\-length}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-get\-\_\-length}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} String\-Vector\-\_\-get\-\_\-length (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_a85a8caa2729732784d93c6adc0f74a94}


Definition at line 145 of file vector.\-c.



References Vector\-\_\-get\-\_\-length().



Referenced by String\-Vector\-\_\-fprint(), and String\-Vector\-\_\-fprint1().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-new@{String\-Vector\-\_\-new}}
\index{String\-Vector\-\_\-new@{String\-Vector\-\_\-new}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-new}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} String\-Vector\-\_\-new (
\begin{DoxyParamCaption}
\item[{{\bf int}}]{len, }
\item[{{\bf int}}]{delete\-\_\-element\-\_\-strings}
\end{DoxyParamCaption}
)}\label{vector_8h_a040ef1c09f8285350ab7be94c531718f}


Definition at line 121 of file vector.\-c.



References nulldealloactor(), strdealloactor(), and Vector\-\_\-new().



Referenced by String\-Vector\-\_\-part().

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-part@{String\-Vector\-\_\-part}}
\index{String\-Vector\-\_\-part@{String\-Vector\-\_\-part}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-part}]{\setlength{\rightskip}{0pt plus 5cm}{\bf String\-Vector} String\-Vector\-\_\-part (
\begin{DoxyParamCaption}
\item[{{\bf String\-Vector}}]{v, }
\item[{{\bf int}}]{n, }
\item[{{\bf int} $\ast$}]{selected\-\_\-list}
\end{DoxyParamCaption}
)}\label{vector_8h_ace659945a31defaa6eebc1f6d8e0c8e7}


Definition at line 169 of file vector.\-c.



References M\-A\-L\-L\-O\-C, Sparse\-Matrix\-\_\-struct\-::n, String\-Vector\-\_\-add(), String\-Vector\-\_\-get(), String\-Vector\-\_\-new(), and T\-R\-U\-E.

\index{vector.\-h@{vector.\-h}!String\-Vector\-\_\-reset@{String\-Vector\-\_\-reset}}
\index{String\-Vector\-\_\-reset@{String\-Vector\-\_\-reset}!vector.h@{vector.\-h}}
\subsubsection[{String\-Vector\-\_\-reset}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} String\-Vector\-\_\-reset (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{char $\ast$}]{content, }
\item[{{\bf int}}]{pos}
\end{DoxyParamCaption}
)}\label{vector_8h_ae5deba549e42fd5fd9b9ee47e00eeef6}


Definition at line 149 of file vector.\-c.



References Vector\-\_\-reset().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-add@{Vector\-\_\-add}}
\index{Vector\-\_\-add@{Vector\-\_\-add}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-add}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Vector\-\_\-add (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{void $\ast$}]{stuff}
\end{DoxyParamCaption}
)}\label{vector_8h_a34fc5ffc1163eebf5c96d15d88983cfc}


Definition at line 43 of file vector.\-c.



References vector\-\_\-struct\-::len, M\-A\-X, vector\-\_\-struct\-::maxlen, N\-U\-L\-L, vector\-\_\-struct\-::size\-\_\-of\-\_\-elem, vector\-\_\-struct\-::v, and Vector\-\_\-assign().



Referenced by Integer\-Vector\-\_\-add(), and String\-Vector\-\_\-add().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-delete@{Vector\-\_\-delete}}
\index{Vector\-\_\-delete@{Vector\-\_\-delete}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-delete}]{\setlength{\rightskip}{0pt plus 5cm}void Vector\-\_\-delete (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_aa341860946dd0a2f28b0da3aba9199e0}


Definition at line 53 of file vector.\-c.



References vector\-\_\-struct\-::deallocator, vector\-\_\-struct\-::len, N\-U\-L\-L, vector\-\_\-struct\-::size\-\_\-of\-\_\-elem, and vector\-\_\-struct\-::v.



Referenced by Integer\-Vector\-\_\-delete(), and String\-Vector\-\_\-delete().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-get@{Vector\-\_\-get}}
\index{Vector\-\_\-get@{Vector\-\_\-get}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-get}]{\setlength{\rightskip}{0pt plus 5cm}void$\ast$ Vector\-\_\-get (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{{\bf int}}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_a15c9200066d160663c92542854978e95}


Definition at line 64 of file vector.\-c.



References vector\-\_\-struct\-::len, N\-U\-L\-L, vector\-\_\-struct\-::size\-\_\-of\-\_\-elem, and vector\-\_\-struct\-::v.



Referenced by Integer\-Vector\-\_\-get(), and String\-Vector\-\_\-get().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-get\-\_\-length@{Vector\-\_\-get\-\_\-length}}
\index{Vector\-\_\-get\-\_\-length@{Vector\-\_\-get\-\_\-length}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-get\-\_\-length}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} Vector\-\_\-get\-\_\-length (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v}
\end{DoxyParamCaption}
)}\label{vector_8h_a0d7252c56d02708fb12329ea54833c3b}


Definition at line 69 of file vector.\-c.



References vector\-\_\-struct\-::len.



Referenced by Integer\-Vector\-\_\-get\-\_\-length(), and String\-Vector\-\_\-get\-\_\-length().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-new@{Vector\-\_\-new}}
\index{Vector\-\_\-new@{Vector\-\_\-new}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-new}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Vector\-\_\-new (
\begin{DoxyParamCaption}
\item[{{\bf int}}]{maxlen, }
\item[{size\-\_\-t}]{size\-\_\-of\-\_\-elem, }
\item[{void($\ast$)(void $\ast$v)}]{deallocator}
\end{DoxyParamCaption}
)}\label{vector_8h_a595ce69777dd610ce25a06053f5a2326}


Definition at line 18 of file vector.\-c.



References vector\-\_\-struct\-::deallocator, vector\-\_\-struct\-::len, vector\-\_\-struct\-::maxlen, N\-U\-L\-L, vector\-\_\-struct\-::size\-\_\-of\-\_\-elem, and vector\-\_\-struct\-::v.



Referenced by Integer\-Vector\-\_\-new(), and String\-Vector\-\_\-new().

\index{vector.\-h@{vector.\-h}!Vector\-\_\-reset@{Vector\-\_\-reset}}
\index{Vector\-\_\-reset@{Vector\-\_\-reset}!vector.h@{vector.\-h}}
\subsubsection[{Vector\-\_\-reset}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Vector} Vector\-\_\-reset (
\begin{DoxyParamCaption}
\item[{{\bf Vector}}]{v, }
\item[{void $\ast$}]{stuff, }
\item[{{\bf int}}]{i}
\end{DoxyParamCaption}
)}\label{vector_8h_a0ae6638c668e85c5bb6b15162b840310}


Definition at line 36 of file vector.\-c.



References vector\-\_\-struct\-::deallocator, vector\-\_\-struct\-::len, N\-U\-L\-L, vector\-\_\-struct\-::size\-\_\-of\-\_\-elem, vector\-\_\-struct\-::v, and Vector\-\_\-assign().



Referenced by Integer\-Vector\-\_\-reset(), and String\-Vector\-\_\-reset().

