123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248 |
- #ifndef CLIENT_TABLE_H
- #define CLIENT_TABLE_H
- /*!
- * \file
- */
- #ifdef __cplusplus
- extern "C" {
- #endif
- #include "service_table.h"
- #include "upnp.h"
- #include "UpnpString.h"
- #include "upnp_timeout.h"
- #include "uri.h"
- #include "TimerThread.h"
- #include <stdio.h>
- #include <stdlib.h>
- #include <time.h>
- extern TimerThread gTimerThread;
- #ifdef INCLUDE_CLIENT_APIS
- typedef struct s_ClientSubscription ClientSubscription;
- /*!
- * \brief Constructor.
- */
- ClientSubscription *UpnpClientSubscription_new();
- /*!
- * \brief Destructor.
- */
- void UpnpClientSubscription_delete(
- /*! [in] The \b this pointer. */
- ClientSubscription *p);
- /*!
- * \brief Copy Constructor.
- */
- ClientSubscription *UpnpClientSubscription_dup(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief Assignment operator.
- */
- void UpnpClientSubscription_assign(
- /*! [in] The \b this pointer. */
- ClientSubscription *q,
- const ClientSubscription *p);
- /*!
- * \brief
- */
- int UpnpClientSubscription_get_RenewEventId(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief
- */
- void UpnpClientSubscription_set_RenewEventId(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- /*! [in] . */
- int n);
- /*!
- * \brief
- */
- const UpnpString *UpnpClientSubscription_get_SID(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief
- */
- void UpnpClientSubscription_set_SID(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const UpnpString *s);
- /*!
- * \brief
- */
- void UpnpClientSubscription_strcpy_SID(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const char *s);
- /*!
- * \brief
- */
- const UpnpString *UpnpClientSubscription_get_ActualSID(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief
- */
- void UpnpClientSubscription_set_ActualSID(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const UpnpString *s);
- /*!
- * \brief
- */
- void UpnpClientSubscription_strcpy_ActualSID(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const char *s);
- /*!
- * \brief
- */
- const UpnpString *UpnpClientSubscription_get_EventURL(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief
- */
- void UpnpClientSubscription_set_EventURL(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const UpnpString *s);
- /*!
- * \brief
- */
- void UpnpClientSubscription_strcpy_EventURL(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- const char *s);
- /*!
- * \brief
- */
- ClientSubscription *UpnpClientSubscription_get_Next(
- /*! [in] The \b this pointer. */
- const ClientSubscription *p);
- /*!
- * \brief
- */
- void UpnpClientSubscription_set_Next(
- /*! [in] The \b this pointer. */
- ClientSubscription *p,
- ClientSubscription *q);
- /*!
- * \brief Free memory allocated for client subscription data.
- *
- * Remove timer thread associated with this subscription event.
- */
- void free_client_subscription(
- /*! [in] Client subscription to be freed. */
- ClientSubscription *sub);
- /*!
- * \brief Free the client subscription table.
- */
- void freeClientSubList(
- /*! [in] Client subscription list to be freed. */
- ClientSubscription *list);
- /*!
- * \brief Remove the client subscription matching the subscritpion id
- * represented by the const Upnp_SID sid parameter from the table and
- * update the table.
- */
- void RemoveClientSubClientSID(
- /*! [in] Head of the subscription list. */
- ClientSubscription **head,
- /*! [in] Subscription ID to be mactched. */
- const UpnpString *sid);
- /*!
- * \brief Return the client subscription from the client table that matches
- * const Upnp_SID sid subscrition id value.
- *
- * \return The matching subscription.
- */
- ClientSubscription *GetClientSubClientSID(
- /*! [in] Head of the subscription list. */
- ClientSubscription *head,
- /*! [in] Subscription ID to be mactched. */
- const UpnpString *sid);
- /*!
- * \brief Returns the client subscription from the client subscription table
- * that has the matching token *sid buffer value.
- *
- * \return The matching subscription.
- */
- ClientSubscription *GetClientSubActualSID(
- /*! [in] Head of the subscription list. */
- ClientSubscription *head,
- /*! [in] Subscription ID to be mactched. */
- token *sid);
- #endif /* INCLUDE_CLIENT_APIS */
- #ifdef __cplusplus
- }
- #endif /* __cplusplus */
- #endif /* CLIENT_TABLE_H */
|