\hypertarget{group__Ecore__Con__Server__Group}{}\section{Ecore Connection Server Functions}
\label{group__Ecore__Con__Server__Group}\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}}


This group of functions is applied to an Ecore\+\_\+\+Con\+\_\+\+Server object.  


\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} Ecore\+\_\+\+Con\+\_\+\+Server $\ast$ \hyperlink{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{ecore\+\_\+con\+\_\+server\+\_\+add} (Ecore\+\_\+\+Con\+\_\+\+Type type, const char $\ast$name, int port, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Create a server to listen for connections. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN \hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$ {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+eo\+\_\+base\+\_\+constructor} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga65e56158c3cf09d69acdf740c9dec226}{}\label{group__Ecore__Con__Server__Group_ga65e56158c3cf09d69acdf740c9dec226}

\item 
static E\+O\+L\+I\+AN \hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$ {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+eo\+\_\+base\+\_\+finalize} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_gaf83d4e8b3e338ade06fd23245fae63bd}{}\label{group__Ecore__Con__Server__Group_gaf83d4e8b3e338ade06fd23245fae63bd}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} Ecore\+\_\+\+Con\+\_\+\+Server $\ast$ \hyperlink{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{ecore\+\_\+con\+\_\+server\+\_\+connect} (Ecore\+\_\+\+Con\+\_\+\+Type type, const char $\ast$name, int port, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Create a connection to the specified server and return an associated object. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN \hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$ {\bfseries \+\_\+efl\+\_\+network\+\_\+connector\+\_\+eo\+\_\+base\+\_\+finalize} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$obj, void $\ast$pd)\hypertarget{group__Ecore__Con__Server__Group_ga98d2a4501ccd3fb6e1092745f830b326}{}\label{group__Ecore__Con__Server__Group_ga98d2a4501ccd3fb6e1092745f830b326}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void \hyperlink{group__Ecore__Con__Server__Group_ga468eec82ada0234b6ea2b5b8d6e25407}{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, double timeout)
\begin{DoxyCompactList}\small\item\em Set the default time after which an inactive client will be disconnected. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+timeout\+\_\+set} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, double timeout)\hypertarget{group__Ecore__Con__Server__Group_ga079ad5f8885e641df7ba7909fde7338d}{}\label{group__Ecore__Con__Server__Group_ga079ad5f8885e641df7ba7909fde7338d}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} double \hyperlink{group__Ecore__Con__Server__Group_ga50906ed9ec7845aa3bfe21998b646345}{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Get the default time after which an inactive client will be disconnected. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN double {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+timeout\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga4907662f52e401b071019c215f3bfb02}{}\label{group__Ecore__Con__Server__Group_ga4907662f52e401b071019c215f3bfb02}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void $\ast$ \hyperlink{group__Ecore__Con__Server__Group_ga79c76b9f725ceda216e9c7e5caf6cbd9}{ecore\+\_\+con\+\_\+server\+\_\+del} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Close the connection and free the given server. \end{DoxyCompactList}\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void $\ast$ \hyperlink{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Retrieve the data associated with the given server. \end{DoxyCompactList}\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void $\ast$ \hyperlink{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, void $\ast$data)
\begin{DoxyCompactList}\small\item\em Set the data associated with the given server. \end{DoxyCompactList}\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} \hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool} \hyperlink{group__Ecore__Con__Server__Group_ga68bd9a81d91669aa6c85e41460acb100}{ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Retrieve whether the given server is currently connected. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN \hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool} {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+connected\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga236f57964409f96b1b0093417e476901}{}\label{group__Ecore__Con__Server__Group_ga236f57964409f96b1b0093417e476901}

\item 
static E\+O\+L\+I\+AN const \hyperlink{group__Eina__List__Group_ga3295e1210efea1fb0fd6acbf3cbc1f29}{Eina\+\_\+\+List} $\ast$ {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+clients\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_gaef2e5f429938191533e1af304562eea1}{}\label{group__Ecore__Con__Server__Group_gaef2e5f429938191533e1af304562eea1}

\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+connection\+\_\+type\+\_\+set} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, Ecore\+\_\+\+Con\+\_\+\+Type type)\hypertarget{group__Ecore__Con__Server__Group_ga3700bd2721ff68d6c7d07ca0dfe993da}{}\label{group__Ecore__Con__Server__Group_ga3700bd2721ff68d6c7d07ca0dfe993da}

\item 
static E\+O\+L\+I\+AN Ecore\+\_\+\+Con\+\_\+\+Type {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+connection\+\_\+type\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga41040da16c57ea8659628d420f3f4a64}{}\label{group__Ecore__Con__Server__Group_ga41040da16c57ea8659628d420f3f4a64}

\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+name\+\_\+set} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, const char $\ast$name)\hypertarget{group__Ecore__Con__Server__Group_gae5c4b21e4e3f9142df0aad1ee6b60782}{}\label{group__Ecore__Con__Server__Group_gae5c4b21e4e3f9142df0aad1ee6b60782}

\item 
static E\+O\+L\+I\+AN const char $\ast$ {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+name\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_gae1bb3f4e52b09f32fb310fa1e997c7c5}{}\label{group__Ecore__Con__Server__Group_gae1bb3f4e52b09f32fb310fa1e997c7c5}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} int \hyperlink{group__Ecore__Con__Server__Group_gac21ef0f2db46b32042160b83534138f9}{ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Retrieve the server port in use. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+port\+\_\+set} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, int port)\hypertarget{group__Ecore__Con__Server__Group_ga4b938c65ad5e53613d905e39f31d40bd}{}\label{group__Ecore__Con__Server__Group_ga4b938c65ad5e53613d905e39f31d40bd}

\item 
static E\+O\+L\+I\+AN int {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+port\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_gad8df57e76272fca970513c96a76dcf49}{}\label{group__Ecore__Con__Server__Group_gad8df57e76272fca970513c96a76dcf49}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} int \hyperlink{group__Ecore__Con__Server__Group_gadf16abc2d4fc16a8b65709eab2cd8337}{ecore\+\_\+con\+\_\+server\+\_\+send} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, const void $\ast$data, int size)
\begin{DoxyCompactList}\small\item\em Send the given data to the given server. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN int {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+send} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, const void $\ast$data, int size)\hypertarget{group__Ecore__Con__Server__Group_gaeefd7d6dc5f2afed5bcabe8fd7d20021}{}\label{group__Ecore__Con__Server__Group_gaeefd7d6dc5f2afed5bcabe8fd7d20021}

\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, int client\+\_\+limit, char reject\+\_\+excess\+\_\+clients)\hypertarget{group__Ecore__Con__Server__Group_gaffda35fb64c7db65eda1b4acd459b06c}{}\label{group__Ecore__Con__Server__Group_gaffda35fb64c7db65eda1b4acd459b06c}

\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr, int $\ast$client\+\_\+limit, char $\ast$reject\+\_\+excess\+\_\+clients)\hypertarget{group__Ecore__Con__Server__Group_gac9c065d435ea2c7f2e7893019c347e92}{}\label{group__Ecore__Con__Server__Group_gac9c065d435ea2c7f2e7893019c347e92}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} const char $\ast$ \hyperlink{group__Ecore__Con__Server__Group_gaea2a907ae4ca478a360928fd16654d45}{ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Get the IP address of a server that has been connected to. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN const char $\ast$ {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+ip\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga48139e1db660f94abc5c58ef875fda47}{}\label{group__Ecore__Con__Server__Group_ga48139e1db660f94abc5c58ef875fda47}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} double \hyperlink{group__Ecore__Con__Server__Group_ga1f7c1040e60e9e9a53a9a01f70aa52b3}{ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Check how long a server has been connected. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN double {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+uptime\+\_\+get} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga8e9331d6c91ddce038ee7326b93d2536}{}\label{group__Ecore__Con__Server__Group_ga8e9331d6c91ddce038ee7326b93d2536}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void \hyperlink{group__Ecore__Con__Server__Group_ga3ddb6c88484b59a1f5a5bacb8b6e60fe}{ecore\+\_\+con\+\_\+server\+\_\+flush} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Flush all pending data to the given server. \end{DoxyCompactList}\item 
static E\+O\+L\+I\+AN void {\bfseries \+\_\+ecore\+\_\+con\+\_\+server\+\_\+ecore\+\_\+con\+\_\+base\+\_\+flush} (\hyperlink{group__Eo_ga9f3010a50b61a892d41f4ec2bda73f4c}{Eo} $\ast$obj, Ecore\+\_\+\+Con\+\_\+\+Server\+\_\+\+Data $\ast$svr)\hypertarget{group__Ecore__Con__Server__Group_ga59370dd666feb4cb5c48bc20d62fd21c}{}\label{group__Ecore__Con__Server__Group_ga59370dd666feb4cb5c48bc20d62fd21c}

\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} void \hyperlink{group__Ecore__Con__Server__Group_gabaef36c991be8922766611c75372ced4}{ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set} (Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, int client\+\_\+limit, char reject\+\_\+excess\+\_\+clients)
\begin{DoxyCompactList}\small\item\em Set a limit on the number of clients that can be handled concurrently by the given server, and a policy on what to do if excess clients try to connect. \end{DoxyCompactList}\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} int \hyperlink{group__Ecore__Con__Server__Group_ga1a97c1a6eafdf856643b586729de00b5}{ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)
\begin{DoxyCompactList}\small\item\em Get the fd that the server is connected to. \end{DoxyCompactList}\item 
\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI} int \hyperlink{group__Ecore__Con__Server__Group_ga43decb7ba52a2b14cfa563b60659491c}{ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get} (const Ecore\+\_\+\+Con\+\_\+\+Client $\ast$cl)
\begin{DoxyCompactList}\small\item\em Get the fd that the client is connected to. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
This group of functions is applied to an Ecore\+\_\+\+Con\+\_\+\+Server object. 

Functions that operate on Ecore server objects.

It doesn\textquotesingle{}t mean that they should be used in the server application, but on the server object. In fact, most of them should be used in the client application, when retrieving information or sending data.

Setting up a server is very simple\+: you just need to start it with \hyperlink{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{ecore\+\_\+con\+\_\+server\+\_\+add()} and setup some callbacks to the events \hyperlink{group__Ecore__Con__Events__Group_ga2ccb9d84c4e5480a787e4672af3e353f}{E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+C\+L\+I\+E\+N\+T\+\_\+\+A\+DD}, \hyperlink{group__Ecore__Con__Events__Group_ga0daddd73ab2ab92cbfd91f50ea344e12}{E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+C\+L\+I\+E\+N\+T\+\_\+\+D\+EL} and \hyperlink{group__Ecore__Con__Events__Group_gafb9ce301001338915a45969e4d11d016}{E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+C\+L\+I\+E\+N\+T\+\_\+\+D\+A\+TA}, that will be called when a client is communicating with the server\+:


\begin{DoxyCode}
\textcolor{keywordflow}{if} (!(svr = \hyperlink{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{ecore\_con\_server\_add}(\hyperlink{group__Ecore__Con__Lib__Group_gga4862bfa05383e6e16a1dfc6eafc90564ab02a4b8522d1ed409cfb24131b24c4ed}{ECORE\_CON\_REMOTE\_TCP}, \textcolor{stringliteral}{"127.0.0.1"},
       8080, NULL)))
  exit(1);

\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_ga2ccb9d84c4e5480a787e4672af3e353f}{ECORE\_CON\_EVENT\_CLIENT\_ADD}, 
      \_add\_cb, NULL);
\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_ga0daddd73ab2ab92cbfd91f50ea344e12}{ECORE\_CON\_EVENT\_CLIENT\_DEL}, 
      \_del\_cb, NULL);
\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_gafb9ce301001338915a45969e4d11d016}{ECORE\_CON\_EVENT\_CLIENT\_DATA}, 
      \_data\_cb, NULL);

\hyperlink{group__Ecore__Main__Loop__Group_gaf103b9f668bb3e4fed12e52c6180132d}{ecore\_main\_loop\_begin}();
\end{DoxyCode}


The function \hyperlink{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{ecore\+\_\+con\+\_\+server\+\_\+connect()} can be used to write a client that connects to a server. The resulting code will be very similar to the server code\+:


\begin{DoxyCode}
\textcolor{keywordflow}{if} (!(svr = \hyperlink{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{ecore\_con\_server\_connect}(
      \hyperlink{group__Ecore__Con__Lib__Group_gga4862bfa05383e6e16a1dfc6eafc90564ab02a4b8522d1ed409cfb24131b24c4ed}{ECORE\_CON\_REMOTE\_TCP}, \textcolor{stringliteral}{"127.0.0.1"}, 8080, NULL)))
  exit(1);

\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_ga4eed60012259c24f9ac75852c5ec1950}{ECORE\_CON\_EVENT\_SERVER\_ADD}, 
      \_add\_cb, NULL);
\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_gabf1abac1d209506c2813837e36dfe37b}{ECORE\_CON\_EVENT\_SERVER\_DEL}, 
      \_del\_cb, NULL);
\hyperlink{group__Ecore__Event__Group_gae75b0b1b2c50e73b8e42afc628b00a62}{ecore\_event\_handler\_add}(\hyperlink{group__Ecore__Con__Events__Group_ga4bd54e9f3c04f7d601bd15b2e109f050}{ECORE\_CON\_EVENT\_SERVER\_DATA}, 
      \_data\_cb, NULL);

\hyperlink{group__Ecore__Main__Loop__Group_gaf103b9f668bb3e4fed12e52c6180132d}{ecore\_main\_loop\_begin}();
\end{DoxyCode}


After these two pieces of code are executed, respectively, in the server and client code, the server will be up and running and the client will try to connect to it. The connection, with its subsequent messages being sent from server to client and client to server, can be represented in the following sequence diagram\+:



 
\begin{DoxyImageNoCaption}
  \mbox{\includegraphics[width=\textwidth]{ecore_con-client-server}}
\end{DoxyImageNoCaption}


Please notice the important difference between these two codes\+: the first is used for writing a {\bfseries server}, while the second should be used for writing a {\bfseries client}.

A reference for the {\ttfamily client} functions can be found at \hyperlink{group__Ecore__Con__Client__Group}{Ecore Connection Client Functions}.

Examples of usage for this A\+PI can be found here\+: \begin{DoxyItemize}
\item \hyperlink{ecore_con_server_simple_example_c}{Ecore\+\_\+\+Con -\/ Creating a server} \item \hyperlink{ecore_con_client_simple_example_c}{Ecore\+\_\+\+Con -\/ Creating a client} \end{DoxyItemize}


\subsection{Function Documentation}
\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+add@{ecore\+\_\+con\+\_\+server\+\_\+add}}
\index{ecore\+\_\+con\+\_\+server\+\_\+add@{ecore\+\_\+con\+\_\+server\+\_\+add}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+add(\+Ecore\+\_\+\+Con\+\_\+\+Type type, const char $\ast$name, int port, const void $\ast$data)}{ecore_con_server_add(Ecore_Con_Type type, const char *name, int port, const void *data)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} Ecore\+\_\+\+Con\+\_\+\+Server $\ast$ ecore\+\_\+con\+\_\+server\+\_\+add (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Type}]{type, }
\item[{const char $\ast$}]{name, }
\item[{int}]{port, }
\item[{const void $\ast$}]{data}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{}\label{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}


Create a server to listen for connections. 


\begin{DoxyParams}{Parameters}
{\em type} & The connection type. \\
\hline
{\em name} & Name to associate with the socket. It is used when generating the socket name of a Unix socket, or for determining what host to listen on for T\+CP sockets. {\ttfamily N\+U\+LL} will not be accepted. \\
\hline
{\em port} & Number to identify socket. When a Unix socket is used, it becomes part of the socket name. When a T\+CP socket is used, it is used as the T\+CP port. \\
\hline
{\em data} & Data to associate with the created Ecore\+\_\+\+Con\+\_\+\+Server object. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A new Ecore\+\_\+\+Con\+\_\+\+Server.
\end{DoxyReturn}
The socket on which the server listens depends on the connection type\+: \begin{DoxyItemize}
\item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+U\+S\+ER}, the server will listen on the Unix socket. The path to the socket is taken from X\+D\+G\+\_\+\+R\+U\+N\+T\+I\+M\+E\+\_\+\+D\+IR, if that is not set, then from H\+O\+ME, even if this is not set, then from T\+M\+P\+D\+IR. If none is set, then path would be /tmp. From this path socket would be created as \char`\"{}\mbox{[}path\mbox{]}/.\+ecore/\mbox{[}name\mbox{]}/\mbox{[}port\mbox{]}\char`\"{}. If port is negetive, then \char`\"{}\mbox{[}path\mbox{]}/.\+ecore/\mbox{[}name\mbox{]}\char`\"{}. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+S\+Y\+S\+T\+EM}, the server will listen on Unix socket \char`\"{}/tmp/.\+ecore\+\_\+service$\vert$\mbox{[}name\mbox{]}$\vert$\mbox{[}port\mbox{]}\char`\"{}. If port is negetive, then \char`\"{}/tmp/.\+ecore\+\_\+service$\vert$\mbox{[}name\mbox{]}\char`\"{}. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+A\+B\+S\+T\+R\+A\+CT}, then port number is not considered while creating the socket. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+T\+CP}, the server will listen on T\+CP port {\ttfamily port}.\end{DoxyItemize}
More information about the {\ttfamily type} can be found at \hyperlink{group__Ecore__Con__Lib__Group_ga4862bfa05383e6e16a1dfc6eafc90564}{\+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Type}.

The {\ttfamily data} parameter can be fetched later using \hyperlink{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get()} or changed with \hyperlink{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set()}. \begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_server_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+example.\+c}, and \hyperlink{ecore_con_server_simple_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+A\+D\+\_\+\+C\+E\+RT, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+A\+B\+S\+T\+R\+A\+CT, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+S\+Y\+S\+T\+EM, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+U\+S\+ER, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+B\+R\+O\+A\+D\+C\+A\+ST, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+C\+O\+RK, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+M\+C\+A\+ST, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+N\+O\+D\+E\+L\+AY, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+T\+CP, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+U\+DP, ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set(), ecore\+\_\+time\+\_\+get(), E\+I\+N\+A\+\_\+\+F\+A\+L\+SE, eina\+\_\+list\+\_\+append(), E\+I\+N\+A\+\_\+\+T\+R\+UE, and eo\+\_\+add.



Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+add().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+connect@{ecore\+\_\+con\+\_\+server\+\_\+connect}}
\index{ecore\+\_\+con\+\_\+server\+\_\+connect@{ecore\+\_\+con\+\_\+server\+\_\+connect}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+connect(\+Ecore\+\_\+\+Con\+\_\+\+Type type, const char $\ast$name, int port, const void $\ast$data)}{ecore_con_server_connect(Ecore_Con_Type type, const char *name, int port, const void *data)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} Ecore\+\_\+\+Con\+\_\+\+Server $\ast$ ecore\+\_\+con\+\_\+server\+\_\+connect (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Type}]{type, }
\item[{const char $\ast$}]{name, }
\item[{int}]{port, }
\item[{const void $\ast$}]{data}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{}\label{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}


Create a connection to the specified server and return an associated object. 


\begin{DoxyParams}{Parameters}
{\em type} & The connection type. \\
\hline
{\em name} & Name used when determining what socket to connect to. It is used to generate the socket name when the socket is a Unix socket. It is used as the hostname when connecting with a T\+CP socket. \\
\hline
{\em port} & Number to identify the socket to connect to. Used when generating the socket name for a Unix socket, or as the T\+CP port when connecting to a T\+CP socket. \\
\hline
{\em data} & Data to associate with the created Ecore\+\_\+\+Con\+\_\+\+Server object. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A new Ecore\+\_\+\+Con\+\_\+\+Server.
\end{DoxyReturn}
The socket to which the connection is made depends on the connection type\+: \begin{DoxyItemize}
\item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+U\+S\+ER}, the server will conect to the Unix socket. The path to the socket is taken from X\+D\+G\+\_\+\+R\+U\+N\+T\+I\+M\+E\+\_\+\+D\+IR, if that is not set, then from H\+O\+ME, even if this is not set, then from T\+M\+P\+D\+IR. If none is set, then path would be /tmp. From this path the function would connect to socket at \char`\"{}\mbox{[}path\mbox{]}/.\+ecore/\mbox{[}name\mbox{]}/\mbox{[}port\mbox{]}\char`\"{}. If port is negetive, then to socket at \char`\"{}\mbox{[}path\mbox{]}/.\+ecore/\mbox{[}name\mbox{]}\char`\"{}. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+S\+Y\+S\+T\+EM}, the server will connect to Unix socket at \char`\"{}/tmp/.\+ecore\+\_\+service$\vert$\mbox{[}name\mbox{]}$\vert$\mbox{[}port\mbox{]}\char`\"{}. If port is negetive, then to Unix socket at \char`\"{}/tmp/.\+ecore\+\_\+service$\vert$\mbox{[}name\mbox{]}\char`\"{}. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+A\+B\+S\+T\+R\+A\+CT}, then port number is not considered while connecting to socket. \item If {\itshape type} is {\ttfamily E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+T\+CP}, the server will listen on T\+CP port {\ttfamily port}.\end{DoxyItemize}
More information about the {\ttfamily type} can be found at \hyperlink{group__Ecore__Con__Lib__Group_ga4862bfa05383e6e16a1dfc6eafc90564}{\+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Type}.

This function won\textquotesingle{}t block. It will either succeed, or fail due to invalid parameters, failed memory allocation, etc., returning {\ttfamily N\+U\+LL} on that case.

However, even if this call returns a valid Ecore\+\_\+\+Con\+\_\+\+Server, the connection will only be successfully completed if an event of type \hyperlink{group__Ecore__Con__Events__Group_ga4eed60012259c24f9ac75852c5ec1950}{E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+S\+E\+R\+V\+E\+R\+\_\+\+A\+DD} is received. If it fails to complete, an \hyperlink{group__Ecore__Con__Events__Group_gabf1abac1d209506c2813837e36dfe37b}{E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+S\+E\+R\+V\+E\+R\+\_\+\+D\+EL} will be received.

The created object gets deleted automatically if the connection to the server is lost.

The {\ttfamily data} parameter can be fetched later using \hyperlink{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get()} or changed with \hyperlink{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set()}. \begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+example.\+c}, and \hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+A\+D\+\_\+\+C\+E\+RT, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+A\+B\+S\+T\+R\+A\+CT, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+S\+Y\+S\+T\+EM, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+L\+O\+C\+A\+L\+\_\+\+U\+S\+ER, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+N\+O\+\_\+\+P\+R\+O\+XY, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+B\+R\+O\+A\+D\+C\+A\+ST, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+C\+O\+RK, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+N\+O\+D\+E\+L\+AY, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+T\+CP, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+U\+DP, ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set(), eina\+\_\+list\+\_\+append(), eo\+\_\+add, and eo\+\_\+data\+\_\+scope\+\_\+get().



Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+connect().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set}}
\index{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, double timeout)}{ecore_con_server_timeout_set(Ecore_Con_Server *svr, double timeout)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr, }
\item[{double}]{timeout}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga468eec82ada0234b6ea2b5b8d6e25407}{}\label{group__Ecore__Con__Server__Group_ga468eec82ada0234b6ea2b5b8d6e25407}


Set the default time after which an inactive client will be disconnected. 


\begin{DoxyParams}{Parameters}
{\em svr} & The server object \\
\hline
{\em timeout} & The timeout, in seconds, to disconnect after\\
\hline
\end{DoxyParams}
This function is used by the server to set the default idle timeout on clients. If the any of the clients becomes idle for a time higher than this value, it will be disconnected. A value of $<$ 1 disables the idle timeout.

This timeout is not affected by the one set by \hyperlink{group__Ecore__Con__Client__Group_gac96c76af4f6c9d842e52ea38312c73dd}{ecore\+\_\+con\+\_\+client\+\_\+timeout\+\_\+set()}. A client will be disconnected whenever the client or the server timeout is reached. That means, the lower timeout value will be used for that client if \hyperlink{group__Ecore__Con__Client__Group_gac96c76af4f6c9d842e52ea38312c73dd}{ecore\+\_\+con\+\_\+client\+\_\+timeout\+\_\+set()} is used on it.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_ga50906ed9ec7845aa3bfe21998b646345}{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get()} 

\hyperlink{group__Ecore__Con__Client__Group_gac96c76af4f6c9d842e52ea38312c73dd}{ecore\+\_\+con\+\_\+client\+\_\+timeout\+\_\+set()} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_server_simple_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+simple\+\_\+example.\+c}.\end{Desc}
\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_timeout_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} double ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga50906ed9ec7845aa3bfe21998b646345}{}\label{group__Ecore__Con__Server__Group_ga50906ed9ec7845aa3bfe21998b646345}


Get the default time after which an inactive client will be disconnected. 


\begin{DoxyParams}{Parameters}
{\em svr} & The server object \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The timeout, in seconds, to disconnect after
\end{DoxyReturn}
This function is used to get the idle timeout for clients. A value of $<$ 1 means the idle timeout is disabled.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_ga468eec82ada0234b6ea2b5b8d6e25407}{ecore\+\_\+con\+\_\+server\+\_\+timeout\+\_\+set()} 

\hyperlink{group__Ecore__Con__Client__Group_gaa09134e1e8c30f0cc07a57c9bd7788df}{ecore\+\_\+con\+\_\+client\+\_\+timeout\+\_\+get()} 
\end{DoxySeeAlso}
\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+del@{ecore\+\_\+con\+\_\+server\+\_\+del}}
\index{ecore\+\_\+con\+\_\+server\+\_\+del@{ecore\+\_\+con\+\_\+server\+\_\+del}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+del(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_del(Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void $\ast$ ecore\+\_\+con\+\_\+server\+\_\+del (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga79c76b9f725ceda216e9c7e5caf6cbd9}{}\label{group__Ecore__Con__Server__Group_ga79c76b9f725ceda216e9c7e5caf6cbd9}


Close the connection and free the given server. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Data associated with the server when it was created.
\end{DoxyReturn}
All the clients connected to this server will be disconnected.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{ecore\+\_\+con\+\_\+server\+\_\+add}, \hyperlink{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{ecore\+\_\+con\+\_\+server\+\_\+connect} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References eo\+\_\+data\+\_\+scope\+\_\+get().



Referenced by ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get(), and ecore\+\_\+ipc\+\_\+server\+\_\+del().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_data_get(Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void $\ast$ ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}{}\label{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}


Retrieve the data associated with the given server. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The associated data.
\end{DoxyReturn}
\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set()} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References eo\+\_\+data\+\_\+scope\+\_\+get().



Referenced by ecore\+\_\+ipc\+\_\+ssl\+\_\+available\+\_\+get().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set}}
\index{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, void $\ast$data)}{ecore_con_server_data_set(Ecore_Con_Server *svr, void *data)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void $\ast$ ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+set (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr, }
\item[{void $\ast$}]{data}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}{}\label{group__Ecore__Con__Server__Group_ga09ee7d7908fb1588740b19ba22d7c29d}


Set the data associated with the given server. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
{\em data} & The data to associate with {\ttfamily svr} \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The previously associated data, if any.
\end{DoxyReturn}
\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_ga0a03ab73a105ad9a17265966f5683625}{ecore\+\_\+con\+\_\+server\+\_\+data\+\_\+get()} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References eo\+\_\+data\+\_\+scope\+\_\+get().



Referenced by ecore\+\_\+con\+\_\+server\+\_\+add(), ecore\+\_\+con\+\_\+server\+\_\+connect(), and ecore\+\_\+con\+\_\+shutdown().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_connected_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} {\bf Eina\+\_\+\+Bool} ecore\+\_\+con\+\_\+server\+\_\+connected\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga68bd9a81d91669aa6c85e41460acb100}{}\label{group__Ecore__Con__Server__Group_ga68bd9a81d91669aa6c85e41460acb100}


Retrieve whether the given server is currently connected. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
{\ttfamily E\+I\+N\+A\+\_\+\+T\+R\+UE} if the server is connected, {\ttfamily E\+I\+N\+A\+\_\+\+F\+A\+L\+SE} otherwise. 
\end{DoxyReturn}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+connected\+\_\+get().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_port_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} int ecore\+\_\+con\+\_\+server\+\_\+port\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gac21ef0f2db46b32042160b83534138f9}{}\label{group__Ecore__Con__Server__Group_gac21ef0f2db46b32042160b83534138f9}


Retrieve the server port in use. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The server port in use.
\end{DoxyReturn}
The port where the server is listening for connections. \begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}
\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+send@{ecore\+\_\+con\+\_\+server\+\_\+send}}
\index{ecore\+\_\+con\+\_\+server\+\_\+send@{ecore\+\_\+con\+\_\+server\+\_\+send}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+send(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, const void $\ast$data, int size)}{ecore_con_server_send(Ecore_Con_Server *svr, const void *data, int size)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} int ecore\+\_\+con\+\_\+server\+\_\+send (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr, }
\item[{const void $\ast$}]{data, }
\item[{int}]{size}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gadf16abc2d4fc16a8b65709eab2cd8337}{}\label{group__Ecore__Con__Server__Group_gadf16abc2d4fc16a8b65709eab2cd8337}


Send the given data to the given server. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
{\em data} & The given data. \\
\hline
{\em size} & Length of the data, in bytes, to send. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The number of bytes sent. {\ttfamily 0} will be returned if there is an error.
\end{DoxyReturn}
This function will send the given data to the server as soon as the program is back to the main loop. Thus, this function returns immediately (non-\/blocking). If the data needs to be sent {\bfseries now}, call \hyperlink{group__Ecore__Con__Server__Group_ga3ddb6c88484b59a1f5a5bacb8b6e60fe}{ecore\+\_\+con\+\_\+server\+\_\+flush()} after this one.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Client__Group_ga166fd469acaa809faa4247b12d79278f}{ecore\+\_\+con\+\_\+client\+\_\+send()} 

\hyperlink{group__Ecore__Con__Server__Group_ga3ddb6c88484b59a1f5a5bacb8b6e60fe}{ecore\+\_\+con\+\_\+server\+\_\+flush()} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+example.\+c}, and \hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+C\+O\+RK, E\+C\+O\+R\+E\+\_\+\+F\+D\+\_\+\+R\+E\+AD, E\+C\+O\+R\+E\+\_\+\+F\+D\+\_\+\+W\+R\+I\+TE, ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+active\+\_\+set(), eina\+\_\+binbuf\+\_\+append\+\_\+length(), eina\+\_\+binbuf\+\_\+new(), and E\+RR.



Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+send().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_ip_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} const char $\ast$ ecore\+\_\+con\+\_\+server\+\_\+ip\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gaea2a907ae4ca478a360928fd16654d45}{}\label{group__Ecore__Con__Server__Group_gaea2a907ae4ca478a360928fd16654d45}


Get the IP address of a server that has been connected to. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A pointer to an internal string that contains the IP address of the connected server in the form \char`\"{}\+X\+X\+X.\+Y\+Y\+Y.\+Z\+Z\+Z.\+A\+A\+A\char`\"{} IP notation. This string should not be modified or trusted to stay valid after deletion for the {\ttfamily svr} object. If no IP is known {\ttfamily N\+U\+LL} is returned. 
\end{DoxyReturn}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+example.\+c}, and \hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+ip\+\_\+get().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_uptime_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} double ecore\+\_\+con\+\_\+server\+\_\+uptime\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga1f7c1040e60e9e9a53a9a01f70aa52b3}{}\label{group__Ecore__Con__Server__Group_ga1f7c1040e60e9e9a53a9a01f70aa52b3}


Check how long a server has been connected. 


\begin{DoxyParams}{Parameters}
{\em svr} & The server to check \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The total time, in seconds, that the server has been connected/running
\end{DoxyReturn}
This function is used to find out the time that has been elapsed since \hyperlink{group__Ecore__Con__Server__Group_gaf450c4039d5e61d4f7a58d7b67efc1e8}{ecore\+\_\+con\+\_\+server\+\_\+add()} succeeded. \begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_server_simple_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+simple\+\_\+example.\+c}.\end{Desc}


References ecore\+\_\+time\+\_\+get().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+flush@{ecore\+\_\+con\+\_\+server\+\_\+flush}}
\index{ecore\+\_\+con\+\_\+server\+\_\+flush@{ecore\+\_\+con\+\_\+server\+\_\+flush}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+flush(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_flush(Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void ecore\+\_\+con\+\_\+server\+\_\+flush (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga3ddb6c88484b59a1f5a5bacb8b6e60fe}{}\label{group__Ecore__Con__Server__Group_ga3ddb6c88484b59a1f5a5bacb8b6e60fe}


Flush all pending data to the given server. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server.\\
\hline
\end{DoxyParams}
This function will block until all data is sent to the server.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Ecore__Con__Server__Group_gadf16abc2d4fc16a8b65709eab2cd8337}{ecore\+\_\+con\+\_\+server\+\_\+send()} 

\hyperlink{group__Ecore__Con__Client__Group_gaccf37688bb1ecbedc8791b5b43c1595c}{ecore\+\_\+con\+\_\+client\+\_\+flush()} 
\end{DoxySeeAlso}
\begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_client_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+example.\+c}, and \hyperlink{ecore_con_client_simple_example_8c-example}{ecore\+\_\+con\+\_\+client\+\_\+simple\+\_\+example.\+c}.\end{Desc}


Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+flush().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set}}
\index{ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set@{ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set(\+Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr, int client\+\_\+limit, char reject\+\_\+excess\+\_\+clients)}{ecore_con_server_client_limit_set(Ecore_Con_Server *svr, int client_limit, char reject_excess_clients)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} void ecore\+\_\+con\+\_\+server\+\_\+client\+\_\+limit\+\_\+set (
\begin{DoxyParamCaption}
\item[{Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr, }
\item[{int}]{client\+\_\+limit, }
\item[{char}]{reject\+\_\+excess\+\_\+clients}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_gabaef36c991be8922766611c75372ced4}{}\label{group__Ecore__Con__Server__Group_gabaef36c991be8922766611c75372ced4}


Set a limit on the number of clients that can be handled concurrently by the given server, and a policy on what to do if excess clients try to connect. 


\begin{DoxyParams}{Parameters}
{\em svr} & The given server. \\
\hline
{\em client\+\_\+limit} & The maximum number of clients to handle concurrently. -\/1 means unlimited (default). 0 effectively disables the server. \\
\hline
{\em reject\+\_\+excess\+\_\+clients} & Set to 1 to automatically disconnect excess clients as soon as they connect if you are already handling client\+\_\+limit clients. Set to 0 (default) to just hold off on the \char`\"{}accept()\char`\"{} system call until the number of active clients drops. This causes the kernel to queue up to 4096 connections (or your kernel\textquotesingle{}s limit, whichever is lower).\\
\hline
\end{DoxyParams}
Beware that if you set this once ecore is already running, you may already have pending C\+L\+I\+E\+N\+T\+\_\+\+A\+DD events in your event queue. Those clients have already connected and will not be affected by this call. Only clients subsequently trying to connect will be affected. \begin{Desc}
\item[Examples\+: ]\par
\hyperlink{ecore_con_server_simple_example_8c-example}{ecore\+\_\+con\+\_\+server\+\_\+simple\+\_\+example.\+c}.\end{Desc}


Referenced by ecore\+\_\+ipc\+\_\+server\+\_\+client\+\_\+limit\+\_\+set().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get}}
\index{ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get@{ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$svr)}{ecore_con_server_fd_get(const Ecore_Con_Server *svr)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} int ecore\+\_\+con\+\_\+server\+\_\+fd\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Server $\ast$}]{svr}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga1a97c1a6eafdf856643b586729de00b5}{}\label{group__Ecore__Con__Server__Group_ga1a97c1a6eafdf856643b586729de00b5}


Get the fd that the server is connected to. 


\begin{DoxyParams}{Parameters}
{\em svr} & The server object \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The fd, or -\/1 on failure
\end{DoxyReturn}
This function returns the fd which is used by the underlying server connection. It should not be tampered with unless you R\+E\+A\+L\+LY know what you are doing. \begin{DoxyNote}{Note}
This function is only valid for servers created with \hyperlink{group__Ecore__Con__Server__Group_gae3d7391f7da5e0f748d7b6804d010b2f}{ecore\+\_\+con\+\_\+server\+\_\+connect()} 
\end{DoxyNote}
\begin{DoxyWarning}{Warning}
Seriously. Don\textquotesingle{}t use this unless you know what you are doing. 
\end{DoxyWarning}
\begin{DoxySince}{Since}
1.\+1 
\end{DoxySince}


References ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+fd\+\_\+get().

\index{Ecore Connection Server Functions@{Ecore Connection Server Functions}!ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get@{ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get}}
\index{ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get@{ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get}!Ecore Connection Server Functions@{Ecore Connection Server Functions}}
\subsubsection[{\texorpdfstring{ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get(const Ecore\+\_\+\+Con\+\_\+\+Client $\ast$cl)}{ecore_con_client_fd_get(const Ecore_Con_Client *cl)}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf E\+A\+PI} int ecore\+\_\+con\+\_\+client\+\_\+fd\+\_\+get (
\begin{DoxyParamCaption}
\item[{const Ecore\+\_\+\+Con\+\_\+\+Client $\ast$}]{cl}
\end{DoxyParamCaption}
)}\hypertarget{group__Ecore__Con__Server__Group_ga43decb7ba52a2b14cfa563b60659491c}{}\label{group__Ecore__Con__Server__Group_ga43decb7ba52a2b14cfa563b60659491c}


Get the fd that the client is connected to. 


\begin{DoxyParams}{Parameters}
{\em cl} & The client object \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The fd, or -\/1 on failure
\end{DoxyReturn}
This function returns the fd which is used by the underlying client connection. It should not be tampered with unless you R\+E\+A\+L\+LY know what you are doing. \begin{DoxySince}{Since}
1.\+1 
\end{DoxySince}


References \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Add\+::client, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Del\+::client, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Error\+::client, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Data\+::client, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Write\+::client, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Data\+::data, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Data\+::data, D\+BG, E\+C\+O\+R\+E\+\_\+\+C\+A\+L\+L\+B\+A\+C\+K\+\_\+\+C\+A\+N\+C\+EL, E\+C\+O\+R\+E\+\_\+\+C\+A\+L\+L\+B\+A\+C\+K\+\_\+\+R\+E\+N\+EW, ecore\+\_\+con\+\_\+client\+\_\+del(), E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+C\+L\+I\+E\+N\+T\+\_\+\+A\+DD, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+C\+L\+I\+E\+N\+T\+\_\+\+U\+P\+G\+R\+A\+DE, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+P\+R\+O\+X\+Y\+\_\+\+B\+I\+ND, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+S\+E\+R\+V\+E\+R\+\_\+\+A\+DD, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+E\+V\+E\+N\+T\+\_\+\+S\+E\+R\+V\+E\+R\+\_\+\+U\+P\+G\+R\+A\+DE, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+B\+R\+O\+A\+D\+C\+A\+ST, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+C\+O\+RK, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+M\+C\+A\+ST, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+N\+O\+D\+E\+L\+AY, E\+C\+O\+R\+E\+\_\+\+C\+O\+N\+\_\+\+R\+E\+M\+O\+T\+E\+\_\+\+U\+DP, ecore\+\_\+con\+\_\+server\+\_\+del(), ecore\+\_\+event\+\_\+add(), ecore\+\_\+event\+\_\+del(), E\+C\+O\+R\+E\+\_\+\+F\+D\+\_\+\+R\+E\+AD, E\+C\+O\+R\+E\+\_\+\+F\+D\+\_\+\+W\+R\+I\+TE, ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+active\+\_\+get(), ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+active\+\_\+set(), ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+add(), ecore\+\_\+main\+\_\+fd\+\_\+handler\+\_\+del(), ecore\+\_\+time\+\_\+get(), ecore\+\_\+timer\+\_\+add(), ecore\+\_\+timer\+\_\+del(), eina\+\_\+binbuf\+\_\+free(), eina\+\_\+binbuf\+\_\+length\+\_\+get(), eina\+\_\+binbuf\+\_\+remove(), eina\+\_\+binbuf\+\_\+string\+\_\+get(), E\+I\+N\+A\+\_\+\+F\+A\+L\+SE, eina\+\_\+list\+\_\+append(), eina\+\_\+list\+\_\+data\+\_\+find(), E\+I\+N\+A\+\_\+\+L\+I\+S\+T\+\_\+\+F\+R\+EE, eina\+\_\+list\+\_\+remove(), eina\+\_\+list\+\_\+remove\+\_\+list(), eina\+\_\+stringshare\+\_\+add(), eina\+\_\+stringshare\+\_\+del(), E\+I\+N\+A\+\_\+\+T\+R\+UE, eo\+\_\+add, eo\+\_\+data\+\_\+scope\+\_\+get(), eo\+\_\+del(), E\+RR, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Error\+::error, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Error\+::error, fcntl(), I\+NF, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Proxy\+\_\+\+Bind\+::ip, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Proxy\+\_\+\+Bind\+::port, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Add\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Del\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Error\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Data\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Write\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Proxy\+\_\+\+Bind\+::server, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Data\+\_\+\+Received\+::size, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Data\+::size, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Data\+::size, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Client\+\_\+\+Write\+::size, \+\_\+\+Ecore\+\_\+\+Con\+\_\+\+Event\+\_\+\+Server\+\_\+\+Write\+::size, and W\+RN.

