我要评分
获取效率
正确性
完整性
易理解

kupl_event_record

Record an event on a queue to enable subsequent inter-queue synchronization.

Interface Definition

int kupl_event_record(kupl_event_h event, kupl_queue_h queue);

Parameters

Parameter

Type

Description

Input/Output

event

kupl_event_h

Event object to be recorded.

Input

queue

kupl_queue_h

Queue object on which the event is recorded.

Input

Return Value

Success: KUPL_OK

Failure: KUPL_ERROR

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
#include <stdio.h> 
#include <assert.h>
#include "kupl.h" 

int main() 
{ 
    kupl_event_h event = kupl_event_create();
    kupl_queue_h queue = kupl_queue_create();

    int ret = kupl_event_record(event, queue);
    assert(ret == KUPL_OK);

    kupl_queue_destroy(queue);
    kupl_event_destroy(event);
    return 0; 
}

The preceding example demonstrates how to record an event. The kupl_event_record function records the event created by the kupl_event_create function on the queue created by the kupl_queue_create function.