tranger2_set_user_flag()

tranger2_set_user_flag()#

Sets or clears specific bits in the user flag of a record in a topic within the TimeRanger database.

Prototype

int tranger2_set_user_flag(
    json_t      *tranger,
    const char  *topic_name,
    uint64_t     rowid,
    uint32_t     mask,
    BOOL         set
);

Parameters

Key

Type

Description

tranger

json_t *

Pointer to the TimeRanger database instance.

topic_name

const char *

Name of the topic containing the record.

rowid

uint64_t

Unique identifier of the record whose user flag is being modified.

mask

uint32_t

Bitmask specifying which bits in the user flag should be modified.

set

BOOL

If TRUE, the bits specified in mask are set; if FALSE, they are cleared.


Return Value

Returns 0 on success, or a negative error code on failure.

Notes

This function modifies only the bits specified in mask, leaving other bits in the user flag unchanged.

Prototype

// Not applicable in JS

Prototype

# Not applicable in Python
Examples
// TODO C examples
// TODO JS examples
# TODO Python examples