The init method initializes the connection port.
RiCBoolean RiCOSConnectionPort_init(
RiCOSConnectionPort * const me);
me
The RiCOSConnectionPort object
The method returns RiCTRUE if successful.
RiCBoolean RiCOSConnectionPort_init(
RiCOSConnectionPort * const me)
{
RiCBoolean b;
if (me==NULL) return RiCFALSE;
me->m_Buf = NULL;
b = RiCOSMutex_init(&me->m_SendMutex);
b &= RiCOSEventFlag_init(&me->m_AckEventFlag);
me->m_BufSize = 0;
me->m_Connected = 0;
me->m_dispatchfunc = NULL;
me->m_ConnectionThread = NULL;
me->m_ShouldWaitForAck = 1;
me->m_NumberOfMessagesBetweenAck = 0;
RiCOSEventFlag_reset(&me->m_AckEventFlag);
return b;
}