yumapro  24.10-1
YumaPro SDK
Loading...
Searching...
No Matches
plock_cb.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2008 - 2012, Andy Bierman, All Rights Reserved.
3 * Copyright (c) 2012 - 2021, YumaWorks, Inc., All Rights Reserved.
4 *
5 * Unless required by applicable law or agreed to in writing,
6 * software distributed under the License is distributed on an
7 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8 * KIND, either express or implied. See the License for the
9 * specific language governing permissions and limitations
10 * under the License.
11 */
12#ifndef _H_plock_cb
13#define _H_plock_cb
14/* FILE: plock_cb.h
15*********************************************************************
16* *
17* P U R P O S E *
18* *
19*********************************************************************/
20
28/*********************************************************************
29* *
30* C H A N G E H I S T O R Y *
31* *
32*********************************************************************
33
34date init comment
35----------------------------------------------------------------------
3625-jun-10 abb Begun; slpit out from plock.h
37
38*/
39
40#ifndef _H_dlq
41#include "dlq.h"
42#endif
43
44#ifndef _H_status
45#include "status.h"
46#endif
47
48#ifndef _H_tstamp
49#include "tstamp.h"
50#endif
51
52#ifdef __cplusplus
53extern "C" {
54#endif
55
56/********************************************************************
57* *
58* C O N S T A N T S *
59* *
60*********************************************************************/
61
62
63
64/********************************************************************
65* *
66* T Y P E S *
67* *
68*********************************************************************/
69
70
78typedef uint32 plock_id_t;
79
81typedef struct plock_cb_t_ {
82 dlq_hdr_t qhdr;
84 uint32 plock_sesid;
85 dlq_hdr_t plock_xpathpcbQ;
86 dlq_hdr_t plock_resultQ;
87 struct xpath_result_t_ *plock_final_result;
88 xmlChar plock_time[TSTAMP_MIN_SIZE];
90
91
92/********************************************************************
93* *
94* F U N C T I O N S *
95* *
96*********************************************************************/
97
98
108extern plock_cb_t *
109 plock_cb_new (uint32 sid,
110 status_t *res);
111
112
118extern void
120
121
128extern void
129 plock_cb_reset_id (void);
130
131
136#ifdef __cplusplus
137} /* end extern 'C' */
138#endif
139
140#endif /* _H_plock_cb */
dlq provides general double-linked list and queue support:
uint32 plock_id_t
matches lock-id-type in YANG module
Definition: plock_cb.h:78
plock_cb_t * plock_cb_new(uint32 sid, status_t *res)
Create a new partial lock control block.
Definition: plock_cb.c:132
void plock_cb_reset_id(void)
Set the next ID number back to the start.
Definition: plock_cb.c:210
void plock_cb_free(plock_cb_t *plcb)
Free a partial lock control block.
Definition: plock_cb.c:183
status_t
global error return code
Definition: status_enum.h:210
#define TSTAMP_MIN_SIZE
normal minimum buffer size for a tstamp buffer
Definition: tstamp.h:71
Global error messages for status code enumerations.
struct representing 1 configuration database
Definition: plock_cb.h:81
dlq_hdr_t plock_xpathpcbQ
Q of xpath_pcb_t.
Definition: plock_cb.h:85
dlq_hdr_t plock_resultQ
Q of xpath_result_t.
Definition: plock_cb.h:86
uint32 plock_sesid
session holding lock
Definition: plock_cb.h:84
dlq_hdr_t qhdr
queue header
Definition: plock_cb.h:82
plock_id_t plock_id
partial lock ID
Definition: plock_cb.h:83
struct xpath_result_t_ * plock_final_result
final result
Definition: plock_cb.h:87
Timestamp utilities.