\doxysection{osmo\+\_\+use\+\_\+count\+\_\+entry Struct Reference}
\label{structosmo__use__count__entry}\index{osmo\_use\_count\_entry@{osmo\_use\_count\_entry}}


One named counter in the list managed by \doxyref{osmo\+\_\+use\+\_\+count}{p.}{structosmo__use__count}.  




{\ttfamily \#include $<$use\+\_\+count.\+h$>$}

\doxysubsection*{Data Fields}
\begin{DoxyCompactItemize}
\item 
struct \textbf{ llist\+\_\+head} \textbf{ entry}
\begin{DoxyCompactList}\small\item\em Entry in osmo\+\_\+use\+\_\+count-\/$>$use\+\_\+counts. \end{DoxyCompactList}\item 
struct \textbf{ osmo\+\_\+use\+\_\+count} $\ast$ \textbf{ use\+\_\+count}
\begin{DoxyCompactList}\small\item\em Parent use count and backpointer to the talloc\+\_\+object. \end{DoxyCompactList}\item 
const char $\ast$ \textbf{ use}
\begin{DoxyCompactList}\small\item\em Use token string that was passed to \doxyref{osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}{p.}{group__use__count_ga3457c05c5d2b707d99eb01704dc5f233}. \end{DoxyCompactList}\item 
int32\+\_\+t \textbf{ count}
\begin{DoxyCompactList}\small\item\em Current use count amount for only this use token string. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
One named counter in the list managed by \doxyref{osmo\+\_\+use\+\_\+count}{p.}{structosmo__use__count}. 

Gets created as necessary by \doxyref{osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}{p.}{group__use__count_ga3457c05c5d2b707d99eb01704dc5f233}. The total current use count of an object is the sum of all individual osmo\+\_\+use\+\_\+count\+\_\+entry-\/$>$count. \begin{DoxyVerb} object            <--backpointer-+
t|  .osmo_use_count               |
a|     .talloc_object ------------+
l|     .use_counts llist:          use   count
l|->      - osmo_use_count_entry: "foo"  1
o|->      - osmo_use_count_entry: "bar"  3
c|->      - osmo_use_count_entry: "baz"  0  (currently unused entry)
\end{DoxyVerb}
 

\doxysubsection{Field Documentation}
\mbox{\label{structosmo__use__count__entry_ae27451006c39bebe8855bcde9e1b967c}} 
\index{osmo\_use\_count\_entry@{osmo\_use\_count\_entry}!count@{count}}
\index{count@{count}!osmo\_use\_count\_entry@{osmo\_use\_count\_entry}}
\doxysubsubsection{count}
{\footnotesize\ttfamily int32\+\_\+t osmo\+\_\+use\+\_\+count\+\_\+entry\+::count}



Current use count amount for only this use token string. 

If zero, this entry is currently unused and kept around to avoid frequent de-\//allocation. 

Referenced by \textbf{ \+\_\+osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+by()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+repurpose\+\_\+zero\+\_\+entry()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+to\+\_\+str\+\_\+buf()}, and \textbf{ osmo\+\_\+use\+\_\+count\+\_\+total()}.

\mbox{\label{structosmo__use__count__entry_a5a2a03538a19e29d830bf9c29382de24}} 
\index{osmo\_use\_count\_entry@{osmo\_use\_count\_entry}!entry@{entry}}
\index{entry@{entry}!osmo\_use\_count\_entry@{osmo\_use\_count\_entry}}
\doxysubsubsection{entry}
{\footnotesize\ttfamily struct \textbf{ llist\+\_\+head} osmo\+\_\+use\+\_\+count\+\_\+entry\+::entry}



Entry in osmo\+\_\+use\+\_\+count-\/$>$use\+\_\+counts. 



Referenced by \textbf{ \+\_\+osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+create()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+find()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+free()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+make\+\_\+static\+\_\+entries()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+repurpose\+\_\+zero\+\_\+entry()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+to\+\_\+str\+\_\+buf()}, and \textbf{ osmo\+\_\+use\+\_\+count\+\_\+total()}.

\mbox{\label{structosmo__use__count__entry_a91221ed50645c326e449bfe235650f9d}} 
\index{osmo\_use\_count\_entry@{osmo\_use\_count\_entry}!use@{use}}
\index{use@{use}!osmo\_use\_count\_entry@{osmo\_use\_count\_entry}}
\doxysubsubsection{use}
{\footnotesize\ttfamily const char$\ast$ osmo\+\_\+use\+\_\+count\+\_\+entry\+::use}



Use token string that was passed to \doxyref{osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}{p.}{group__use__count_ga3457c05c5d2b707d99eb01704dc5f233}. 



Referenced by \textbf{ \+\_\+osmo\+\_\+use\+\_\+count\+\_\+get\+\_\+put()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+by()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+create()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+find()}, \textbf{ osmo\+\_\+use\+\_\+count\+\_\+repurpose\+\_\+zero\+\_\+entry()}, and \textbf{ osmo\+\_\+use\+\_\+count\+\_\+to\+\_\+str\+\_\+buf()}.

\mbox{\label{structosmo__use__count__entry_a0cc73d52f17a7a3acfa3485d59d8f416}} 
\index{osmo\_use\_count\_entry@{osmo\_use\_count\_entry}!use\_count@{use\_count}}
\index{use\_count@{use\_count}!osmo\_use\_count\_entry@{osmo\_use\_count\_entry}}
\doxysubsubsection{use\_count}
{\footnotesize\ttfamily struct \textbf{ osmo\+\_\+use\+\_\+count}$\ast$ osmo\+\_\+use\+\_\+count\+\_\+entry\+::use\+\_\+count}



Parent use count and backpointer to the talloc\+\_\+object. 



Referenced by \textbf{ osmo\+\_\+use\+\_\+count\+\_\+create()}, and \textbf{ osmo\+\_\+use\+\_\+count\+\_\+make\+\_\+static\+\_\+entries()}.



The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
include/osmocom/core/\textbf{ use\+\_\+count.\+h}\end{DoxyCompactItemize}
