
/*---------------------------------------------------------------------------*/
/* ios_sockets.h                                                             */
/* copyright (c) innovaphone 2015                                            */
/*                                                                           */
/*---------------------------------------------------------------------------*/

class ios_sockets_user_timer : public ITimer {
public:
    ios_sockets_user_timer(IIoMux * ioMux, UTimerSubclass<ios_sockets_user_timer> * owner) : ITimer(ioMux, owner) {};
};

class IosSockets : public IClientSockets,
    public UTimerSubclass<ios_sockets_user_timer>
{
    class IIoMux *iomux;
    UClientSockets * user;
    ios_sockets_user_timer user_timer;

    void TimerOnTimeout(ios_sockets_user_timer * timer);

    void StartTimer(unsigned timeoutMs);
    void CancelTimer();
    void SocketsActive(bool active);
    void RtpSocketsActive(bool active);
    void MulticastReceiveActive(bool active);

public:
    IosSockets(class IIoMux *iomux, UClientSockets * user);
    ~IosSockets();
};

/*---------------------------------------------------------------------------*/
