\hypertarget{functional_8c}{\section{functional.\+c File Reference}
\label{functional_8c}\index{functional.\+c@{functional.\+c}}
}


Functional helper.  


{\ttfamily \#include $<$kdb.\+h$>$}\\*
{\ttfamily \#include $<$stdlib.\+h$>$}\\*
{\ttfamily \#include $<$stdio.\+h$>$}\\*
{\ttfamily \#include $<$limits.\+h$>$}\\*
{\ttfamily \#include $<$errno.\+h$>$}\\*
{\ttfamily \#include $<$string.\+h$>$}\\*
Include dependency graph for functional.\+c\+:
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{functional_8c__incl}
\end{center}
\end{figure}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
int \hyperlink{functional_8c_a5e727c6d8197f5871a2075454b6214f2}{elektra\+Ks\+Filter} (Key\+Set $\ast$result, Key\+Set $\ast$input, int($\ast$filter)(const Key $\ast$k, void $\ast$argument), void $\ast$argument)
\begin{DoxyCompactList}\small\item\em return only those keys from the given keyset that pass the supplied filter function with the supplied argument \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Functional helper. 

\begin{DoxyCopyright}{Copyright}
B\+S\+D License (see doc/\+C\+O\+P\+Y\+I\+N\+G or \href{http://www.libelektra.org}{\tt http\+://www.\+libelektra.\+org}) 
\end{DoxyCopyright}


\subsection{Function Documentation}
\hypertarget{functional_8c_a5e727c6d8197f5871a2075454b6214f2}{\index{functional.\+c@{functional.\+c}!elektra\+Ks\+Filter@{elektra\+Ks\+Filter}}
\index{elektra\+Ks\+Filter@{elektra\+Ks\+Filter}!functional.\+c@{functional.\+c}}
\subsubsection[{elektra\+Ks\+Filter}]{\setlength{\rightskip}{0pt plus 5cm}int elektra\+Ks\+Filter (
\begin{DoxyParamCaption}
\item[{Key\+Set $\ast$}]{result, }
\item[{Key\+Set $\ast$}]{input, }
\item[{int($\ast$)(const Key $\ast$k, void $\ast$argument)}]{filter, }
\item[{void $\ast$}]{argument}
\end{DoxyParamCaption}
)}}\label{functional_8c_a5e727c6d8197f5871a2075454b6214f2}


return only those keys from the given keyset that pass the supplied filter function with the supplied argument 


\begin{DoxyParams}{Parameters}
{\em result} & the keyset that should contain the filtered keys \\
\hline
{\em input} & the keyset whose keys should be filtered \\
\hline
{\em filter} & a function pointer to a function that will be used to filter the keyset. A key will be taken if the function returns a value greater than 0. \\
\hline
{\em argument} & an argument that will be passed to the filter function each time it is called \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
the number of filtered keys if the filter function always returned a positive value, -\/1 otherwise 
\end{DoxyReturn}

\begin{DoxyRetVals}{Return values}
{\em N\+U\+L\+L} & on N\+U\+L\+L pointer \\
\hline
\end{DoxyRetVals}
