Diffusion C API 6.12.0
Loading...
Searching...
No Matches
session trees

Functions

DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_Tdiffusion_branch_mapping_table_builder_init ()
 Initialise a new branch mapping table builder.
DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_Tdiffusion_branch_mapping_table_builder_reset (DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T *builder)
 Reset the stored branch mappings in the branch mapping table builder.
DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_Tdiffusion_branch_mapping_table_builder_add_branch_mapping (DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T *builder, char *session_filter, char *topic_tree_branch)
 Adds a new branch mapping with the specified values.
DIFFUSION_BRANCH_MAPPING_TABLE_Tdiffusion_branch_mapping_table_builder_create_table (DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T *builder, char *session_tree_branch)
 Creates a branch mapping table for the specified session tree branch.
void diffusion_branch_mapping_table_builder_free (DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T *builder)
 Free a branch mapping table builder.
void diffusion_branch_mapping_table_free (DIFFUSION_BRANCH_MAPPING_TABLE_T *table)
 Free a branch mapping table.
char * diffusion_branch_mapping_table_get_session_tree_branch (DIFFUSION_BRANCH_MAPPING_TABLE_T *table)
 Get the session tree branch from a branch mapping table.
LIST_T * diffusion_branch_mapping_table_get_branch_mappings (DIFFUSION_BRANCH_MAPPING_TABLE_T *table)
 Get the branch mappings from a branch mapping table.
void diffusion_branch_mapping_table_free_branch_mappings (LIST_T *branch_mappings)
 Free a list containing branch mappings.
char * diffusion_branch_mapping_get_session_filter (DIFFUSION_BRANCH_MAPPING_T *mapping)
 Get the session filter from a branch mapping.
char * diffusion_branch_mapping_get_topic_tree_branch (DIFFUSION_BRANCH_MAPPING_T *mapping)
 Get the topic tree branch from a branch mapping.
bool diffusion_session_trees_put_branch_mapping_table (SESSION_T *session, const DIFFUSION_SESSION_TREES_PUT_BRANCH_MAPPING_TABLE_PARAMS_T params, DIFFUSION_API_ERROR *api_error)
 Create or replace a branch mapping table.
bool diffusion_session_trees_get_session_tree_branches (SESSION_T *session, const DIFFUSION_SESSION_TREES_GET_SESSION_TREE_BRANCHES_PARAMS_T params, DIFFUSION_API_ERROR *api_error)
 Retrieve the session tree branches of the server's branch mapping tables.
bool diffusion_session_trees_get_branch_mapping_table (SESSION_T *session, const DIFFUSION_SESSION_TREES_GET_BRANCH_MAPPING_TABLE_PARAMS_T params, DIFFUSION_API_ERROR *api_error)
 Retrieve a branch mapping table from the server.

Detailed Description

Function Documentation

◆ diffusion_branch_mapping_get_session_filter()

char * diffusion_branch_mapping_get_session_filter ( DIFFUSION_BRANCH_MAPPING_T * mapping)

Get the session filter from a branch mapping.

Parameters
tableThe branch mapping
Returns
the session filter of the branch mapping if valid or NULL otherwise.

◆ diffusion_branch_mapping_get_topic_tree_branch()

char * diffusion_branch_mapping_get_topic_tree_branch ( DIFFUSION_BRANCH_MAPPING_T * mapping)

Get the topic tree branch from a branch mapping.

Parameters
tableThe branch mapping
Returns
the topic tree branch of the branch mapping if valid or NULL otherwise.

◆ diffusion_branch_mapping_table_builder_add_branch_mapping()

DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * diffusion_branch_mapping_table_builder_add_branch_mapping ( DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * builder,
char * session_filter,
char * topic_tree_branch )

Adds a new branch mapping with the specified values.

Parameters
builderthe branch mapping table builder.
session_filterthe session filter.
topic_tree_branchthe topic tree branch.
Returns
the branch mapping table builder

◆ diffusion_branch_mapping_table_builder_create_table()

DIFFUSION_BRANCH_MAPPING_TABLE_T * diffusion_branch_mapping_table_builder_create_table ( DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * builder,
char * session_tree_branch )

Creates a branch mapping table for the specified session tree branch.

Parameters
session_tree_branchthe session filter.
topic_tree_branchthe .
builderthe branch mapping table builder.
Returns
the branch mapping table builder

◆ diffusion_branch_mapping_table_builder_free()

void diffusion_branch_mapping_table_builder_free ( DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * builder)

Free a branch mapping table builder.

Parameters
builderThe branch mapping table builder.

◆ diffusion_branch_mapping_table_builder_init()

DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * diffusion_branch_mapping_table_builder_init ( )

Initialise a new branch mapping table builder.

diffusion_branch_mapping_table_builder_free should be called on this pointer when no longer needed.

Returns
the branch mapping table builder

◆ diffusion_branch_mapping_table_builder_reset()

DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * diffusion_branch_mapping_table_builder_reset ( DIFFUSION_BRANCH_MAPPING_TABLE_BUILDER_T * builder)

Reset the stored branch mappings in the branch mapping table builder.

Parameters
builderthe branch mapping table builder.
Returns
the branch mapping table builder

◆ diffusion_branch_mapping_table_free()

void diffusion_branch_mapping_table_free ( DIFFUSION_BRANCH_MAPPING_TABLE_T * table)

Free a branch mapping table.

Parameters
tableThe branch mapping table.

◆ diffusion_branch_mapping_table_free_branch_mappings()

void diffusion_branch_mapping_table_free_branch_mappings ( LIST_T * branch_mappings)

Free a list containing branch mappings.

Parameters
branch_mappingsThe list containing the branch mappings

◆ diffusion_branch_mapping_table_get_branch_mappings()

LIST_T * diffusion_branch_mapping_table_get_branch_mappings ( DIFFUSION_BRANCH_MAPPING_TABLE_T * table)

Get the branch mappings from a branch mapping table.

Parameters
tableThe branch mapping table
Returns
a list containing DIFFUSION_BRANCH_MAPPING_T elements if valid or NULL otherwise.

◆ diffusion_branch_mapping_table_get_session_tree_branch()

char * diffusion_branch_mapping_table_get_session_tree_branch ( DIFFUSION_BRANCH_MAPPING_TABLE_T * table)

Get the session tree branch from a branch mapping table.

Parameters
tableThe branch mapping table.
Returns
the session tree branch if present, NULL otherwise.

◆ diffusion_session_trees_get_branch_mapping_table()

bool diffusion_session_trees_get_branch_mapping_table ( SESSION_T * session,
const DIFFUSION_SESSION_TREES_GET_BRANCH_MAPPING_TABLE_PARAMS_T params,
DIFFUSION_API_ERROR * api_error )

Retrieve a branch mapping table from the server.

If there is no branch mapping table at the given session tree branch, this method will return an empty branch mapping table.

Parameters
sessionThe current session. If NULL, this function returns immediately.
paramsParameter structure describing the session tree branch name and the callbacks to be invoked.
api_errorPopulated on API error. Can be NULL.
Returns
true if the operation was successful. False, otherwise. In this case, if a non-NULL api_error pointer has been provided, this will be populated with the error information and should be freed with diffusion_api_error_free.

◆ diffusion_session_trees_get_session_tree_branches()

bool diffusion_session_trees_get_session_tree_branches ( SESSION_T * session,
const DIFFUSION_SESSION_TREES_GET_SESSION_TREE_BRANCHES_PARAMS_T params,
DIFFUSION_API_ERROR * api_error )

Retrieve the session tree branches of the server's branch mapping tables.

The results will only include the session tree branches of branch mapping tables that have at least one branch mapping and for which the calling session has PATH_PERMISSION_READ_TOPIC path permission for the session tree branch.

Individual branch mapping tables can be retrieved using diffusion_session_trees_get_branch_mapping_table.

Parameters
sessionThe current session. If NULL, this function returns immediately.
paramsParameter structure describing the callbacks to be invoked.
api_errorPopulated on API error. Can be NULL.
Returns
true if the operation was successful. False, otherwise. In this case, if a non-NULL api_error pointer has been provided, this will be populated with the error information and should be freed with diffusion_api_error_free.

◆ diffusion_session_trees_put_branch_mapping_table()

bool diffusion_session_trees_put_branch_mapping_table ( SESSION_T * session,
const DIFFUSION_SESSION_TREES_PUT_BRANCH_MAPPING_TABLE_PARAMS_T params,
DIFFUSION_API_ERROR * api_error )

Create or replace a branch mapping table.

The server ensures that a session tree branch has at most one branch mapping table. Putting a new branch mapping table will replace any previous branch mapping table with the same session tree branch. To remove all branch mappings for a session tree branch, put an empty branch mapping table.

Parameters
sessionThe current session. If NULL, this function returns immediately.
paramsParameter structure describing the branch mapping table and the callbacks to be invoked.
api_errorPopulated on API error. Can be NULL.
Returns
true if the operation was successful. False, otherwise. In this case, if a non-NULL api_error pointer has been provided, this will be populated with the error information and should be freed with diffusion_api_error_free.