\hypertarget{elektra_2plugin_8c}{}\doxysection{plugin.\+c File Reference}
\label{elektra_2plugin_8c}\index{plugin.c@{plugin.c}}


Interna of plugin functionality.  


{\ttfamily \#include $<$kdbassert.\+h$>$}\newline
{\ttfamily \#include $<$kdberrors.\+h$>$}\newline
{\ttfamily \#include $<$kdbinternal.\+h$>$}\newline
{\ttfamily \#include $<$kdbversion.\+h$>$}\newline
Include dependency graph for elektra/plugin.c\+:
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{elektra_2plugin_8c__incl}
\end{center}
\end{figure}
\doxysubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
Plugin $\ast$ \mbox{\hyperlink{elektra_2plugin_8c_a32a70a7876542c51d153164ac5108a57}{elektra\+Plugin\+Open}} (const char $\ast$name, Key\+Set $\ast$modules, Key\+Set $\ast$config, Key $\ast$error\+Key)
\begin{DoxyCompactList}\small\item\em Opens a plugin. \end{DoxyCompactList}\item 
size\+\_\+t \mbox{\hyperlink{elektra_2plugin_8c_a9c44a58fa46e132d04a513ff9c453201}{elektra\+Plugin\+Get\+Function}} (Plugin $\ast$plugin, const char $\ast$name)
\begin{DoxyCompactList}\small\item\em Retrieves a function exported by a plugin. \end{DoxyCompactList}\item 
const char $\ast$ \mbox{\hyperlink{elektra_2plugin_8c_aea301339da46627a08ed46cbfd3d2815}{elektra\+Plugin\+Phase\+Name}} (Elektra\+Kdb\+Phase phase)
\begin{DoxyCompactList}\small\item\em Gets a string with the name of the given constant for a plugin phase. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Interna of plugin functionality. 

\begin{DoxyCopyright}{Copyright}
BSD License (see LICENSE.\+md or \href{https://www.libelektra.org}{\texttt{ https\+://www.\+libelektra.\+org}}) 
\end{DoxyCopyright}


\doxysubsection{Function Documentation}
\mbox{\Hypertarget{elektra_2plugin_8c_a9c44a58fa46e132d04a513ff9c453201}\label{elektra_2plugin_8c_a9c44a58fa46e132d04a513ff9c453201}} 
\index{elektra/plugin.c@{elektra/plugin.c}!elektraPluginGetFunction@{elektraPluginGetFunction}}
\index{elektraPluginGetFunction@{elektraPluginGetFunction}!elektra/plugin.c@{elektra/plugin.c}}
\doxysubsubsection{\texorpdfstring{elektraPluginGetFunction()}{elektraPluginGetFunction()}}
{\footnotesize\ttfamily size\+\_\+t elektra\+Plugin\+Get\+Function (\begin{DoxyParamCaption}\item[{Plugin $\ast$}]{plugin,  }\item[{const char $\ast$}]{name }\end{DoxyParamCaption})}



Retrieves a function exported by a plugin. 


\begin{DoxyParams}{Parameters}
{\em plugin} & Plugin handle \\
\hline
{\em name} & Function name. Must be a valid key name suffix. May not contain the sequence \textquotesingle{}..\textquotesingle{} \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Pointer to function. NULL if function not found or not enough memory available 
\end{DoxyReturn}
\mbox{\Hypertarget{elektra_2plugin_8c_a32a70a7876542c51d153164ac5108a57}\label{elektra_2plugin_8c_a32a70a7876542c51d153164ac5108a57}} 
\index{elektra/plugin.c@{elektra/plugin.c}!elektraPluginOpen@{elektraPluginOpen}}
\index{elektraPluginOpen@{elektraPluginOpen}!elektra/plugin.c@{elektra/plugin.c}}
\doxysubsubsection{\texorpdfstring{elektraPluginOpen()}{elektraPluginOpen()}}
{\footnotesize\ttfamily Plugin$\ast$ elektra\+Plugin\+Open (\begin{DoxyParamCaption}\item[{const char $\ast$}]{name,  }\item[{Key\+Set $\ast$}]{modules,  }\item[{Key\+Set $\ast$}]{config,  }\item[{Key $\ast$}]{error\+Key }\end{DoxyParamCaption})}



Opens a plugin. 

The config will be used as is. So be sure to transfer ownership of the config to it, with e.\+g. \mbox{\hyperlink{group__keyset_gac59e4b328245463f1451f68d5106151c}{ks\+Dup()}}. elektra\+Plugin\+Close() will delete the config.

\begin{DoxyReturn}{Returns}
a pointer to a new created plugin or 0 on error 
\end{DoxyReturn}
\mbox{\Hypertarget{elektra_2plugin_8c_aea301339da46627a08ed46cbfd3d2815}\label{elektra_2plugin_8c_aea301339da46627a08ed46cbfd3d2815}} 
\index{elektra/plugin.c@{elektra/plugin.c}!elektraPluginPhaseName@{elektraPluginPhaseName}}
\index{elektraPluginPhaseName@{elektraPluginPhaseName}!elektra/plugin.c@{elektra/plugin.c}}
\doxysubsubsection{\texorpdfstring{elektraPluginPhaseName()}{elektraPluginPhaseName()}}
{\footnotesize\ttfamily const char$\ast$ elektra\+Plugin\+Phase\+Name (\begin{DoxyParamCaption}\item[{Elektra\+Kdb\+Phase}]{phase }\end{DoxyParamCaption})}



Gets a string with the name of the given constant for a plugin phase. 


\begin{DoxyParams}{Parameters}
{\em phase} & The Elektra\+Kdb\+Phase value for which a string representation should be returned\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A string with the name of the given phase. The returned string is a constant value and must never be freed! 
\end{DoxyReturn}

\begin{DoxyRetVals}{Return values}
{\em ???} & if an unknown value for the phase was given \\
\hline
\end{DoxyRetVals}
