USRLOC - List of registered domains. More...
#include <stdio.h>#include "../../str.h"#include "usrloc.h"#include "udomain.h"#include "udomain.h"

Go to the source code of this file.
Definition in file modules_k/usrloc/dlist.h.
| _d | domain name | |
| _p | pointer to domain if found |
Definition at line 633 of file modules_k/usrloc/dlist.c.
References dlist::d, and find_dlist().

| int get_all_ucontacts | ( | void * | buf, | |
| int | len, | |||
| unsigned int | flags, | |||
| unsigned int | part_idx, | |||
| unsigned int | part_max | |||
| ) |
Return list of all contacts for all currently registered users in all domains. The caller must provide buffer of sufficient length for fitting all those contacts. In the case when buffer was exhausted, the function returns estimated amount of additional space needed, in this case the caller is expected to repeat the call using this value as the hint.
Information is packed into the buffer as follows:
+------------+----------+-----+------+-----+ |contact1.len|contact1.s|sock1|flags1|path1| +------------+----------+-----+------+-----+ |contact2.len|contact2.s|sock2|flags2|path1| +------------+----------+-----+------+-----+ |..........................................| +------------+----------+-----+------+-----+ |contactN.len|contactN.s|sockN|flagsN|pathN| +------------+----------+-----+------+-----+ |000000000000| +------------+
| buf | target buffer | |
| len | length of buffer | |
| flags | contact flags | |
| part_idx | part index | |
| part_max | maximal part |
Definition at line 162 of file modules_k/p_usrloc/dlist.c.
References db_mode, DB_ONLY, get_all_db_ucontacts(), and get_all_mem_ucontacts().

| unsigned long get_number_of_users | ( | void | ) |
Definition at line 154 of file modules_k/p_usrloc/dlist.c.
References dlist::d, dlist::next, and udomain::users.
| int get_udomain | ( | const char * | _n, | |
| udomain_t ** | _d | |||
| ) |
| _n | domain name | |
| _d | usrloc domain (location table) |
Find and return usrloc domain.
Find and return a usrloc domain (location table)
| _n | domain name | |
| _d | usrloc domain |
Definition at line 462 of file modules_k/usrloc/dlist.c.
References dlist::d, find_dlist(), _str::len, and _str::s.

| void print_all_udomains | ( | FILE * | _f | ) |
| _f | output file |
Definition at line 567 of file modules_k/usrloc/dlist.c.
References dlist::d, dlist::next, and print_udomain().

| int register_udomain | ( | const char * | _n, | |
| udomain_t ** | _d | |||
| ) |
Registers a new domain with usrloc. If the domain exists, a pointer to existing structure will be returned, otherwise a new domain will be created
| _n | domain name | |
| _d | new created domain |
Definition at line 124 of file modules_k/p_usrloc/dlist.c.
References find_dlist(), _str::len, and _str::s.

| int synchronize_all_udomains | ( | int | istart, | |
| int | istep | |||
| ) |
Definition at line 608 of file modules_k/usrloc/dlist.c.
References dlist::d, db_mode, DB_ONLY, db_timer_udomain(), get_act_time(), mem_timer_udomain(), and dlist::next.

1.7.1