RTS API Documentation  1.10.11
Macros | Functions
switch_limit.h File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define SWITCH_LIMIT_INCR(name)   static switch_status_t name (switch_core_session_t *session, const char *realm, const char *resource, const int max, const int interval)
 
#define SWITCH_LIMIT_RELEASE(name)   static switch_status_t name (switch_core_session_t *session, const char *realm, const char *resource)
 
#define SWITCH_LIMIT_USAGE(name)   static int name (const char *realm, const char *resource, uint32_t *rcount)
 
#define SWITCH_LIMIT_RESET(name)   static switch_status_t name (void)
 
#define SWITCH_LIMIT_INTERVAL_RESET(name)   static switch_status_t name (const char *realm, const char *resource)
 
#define SWITCH_LIMIT_STATUS(name)   static char * name (void)
 
#define LIMIT_IGNORE_TRANSFER_VARIABLE   "limit_ignore_transfer"
 
#define LIMIT_BACKEND_VARIABLE   "limit_backend"
 
#define LIMIT_EVENT_USAGE   "limit::usage"
 
#define LIMIT_DEF_XFER_EXTEN   "limit_exceeded"
 

Functions

SWITCH_BEGIN_EXTERN_C void switch_limit_init (switch_memory_pool_t *pool)
 Initilize the LIMIT Core System. More...
 
switch_status_t switch_limit_incr (const char *backend, switch_core_session_t *session, const char *realm, const char *resource, const int max, const int interval)
 Increment resource. More...
 
switch_status_t switch_limit_release (const char *backend, switch_core_session_t *session, const char *realm, const char *resource)
 Release resource. More...
 
int switch_limit_usage (const char *backend, const char *realm, const char *resource, uint32_t *rcount)
 get usage count for resource More...
 
switch_status_t switch_limit_interval_reset (const char *backend, const char *realm, const char *resource)
 reset interval usage counter for a given resource More...
 
switch_status_t switch_limit_reset (const char *backend)
 reset all usage counters More...
 
void switch_limit_fire_event (const char *backend, const char *realm, const char *resource, uint32_t usage, uint32_t rate, uint32_t max, uint32_t ratemax)
 fire event for limit usage More...
 
char * switch_limit_status (const char *backend)
 retrieve arbitrary status information More...