yumapro  24.10-3
YumaPro SDK
Loading...
Searching...
No Matches
getbulk.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2016 - 2024, YumaWorks, Inc., All Rights Reserved.
3 *
4 * Unless required by applicable law or agreed to in writing,
5 * software distributed under the License is distributed on an
6 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
7 * KIND, either express or implied. See the License for the
8 * specific language governing permissions and limitations
9 * under the License.
10 *
11 */
12#ifndef _H_getbulk
13#define _H_getbulk
14
15/* FILE: getbulk.h
16*********************************************************************
17* *
18* P U R P O S E *
19* *
20*********************************************************************/
21
27#include <xmlstring.h>
28
29#include "dlq.h"
30#include "ncxtypes.h"
31#include "status_enum.h"
32#include "val.h"
33#include "yangapi.h"
34
35#ifdef __cplusplus
36extern "C" {
37#endif
38
39
40/********************************************************************
41* *
42* T Y P E S *
43* *
44*********************************************************************/
45
46
59typedef struct getbulk_cb_t_ {
60
62 struct cfg_template_t_ *source_cfg;
63
65 xmlChar *list_target;
66
68 struct obj_template_t_ *target_obj;
69
71 uint32 count;
72
75
77 uint32 ret_count;
78
79 /* depth parameter set directly in xml_msg_hdr */
80 //uint16 depth;
81
82 /* withdef parameter set directly in xml_msg_hdr */
83 //ncx_withdefaults_t withdef;
84
94
97
100
103
106
112
115
117
118
119/********************************************************************
120* *
121* F U N C T I O N S *
122* *
123*********************************************************************/
124
130extern getbulk_cb_t *
131 getbulk_new_cb (void);
132
133
139extern void
141
142
155extern status_t
157 obj_template_t *obj,
158 uint32 *max_entries,
159 val_value_t **last_entry);
160
161
170extern boolean
172 obj_template_t *obj);
173
174
185extern status_t
187 val_value_t *lastval);
188
189
200extern status_t
202 dlq_hdr_t *keyQ);
203
204
208#ifdef __cplusplus
209} /* end extern 'C' */
210#endif
211
212#endif
dlq provides general double-linked list and queue support:
void getbulk_free_cb(getbulk_cb_t *cb)
Clean and free a getbulk control block.
Definition: getbulk.c:116
status_t getbulk_create_last_keys(getbulk_cb_t *bulk, val_value_t *lastval)
Create the <last-keys> container and clone the keys from the lastval.
Definition: getbulk.c:217
status_t getbulk_check_get2(getbulk_cb_t *bulk, obj_template_t *obj, uint32 *max_entries, val_value_t **last_entry)
Check the GET2 object against the getbulk request to see if it needs to be processed as get-bulk or n...
Definition: getbulk.c:150
status_t getbulk_create_last_keys_get2(getbulk_cb_t *bulk, dlq_hdr_t *keyQ)
Create the <last-keys> container and clone the keys from the lastval; For GET2 callback.
Definition: getbulk.c:281
getbulk_cb_t * getbulk_new_cb(void)
Create a new getbulk control block.
Definition: getbulk.c:96
boolean getbulk_with_get2(getbulk_cb_t *bulk, obj_template_t *obj)
Check the GET2 object against the getbulk request to see if it needs to be processed as get-bulk or n...
Definition: getbulk.c:186
restconf_content_t
RESTCONF content query param enumeration.
Definition: yangapi.h:215
status_t
global error return code
Definition: status_enum.h:210
YANG module data structures Many internal representations of YANG module constructs.
global error status code enumerations
Get Bulk Control BLock.
Definition: getbulk.h:59
xmlChar * list_target
expression identifying the list object to walk
Definition: getbulk.h:65
uint32 ret_count
number of list entries returned
Definition: getbulk.h:77
struct obj_template_t_ * target_obj
back-ptr to the target object template
Definition: getbulk.h:68
int32 start_indent
the requested indent for the list target instances <verbatim> <rpc-reply> <bulk> <data> <foo> <– star...
Definition: getbulk.h:93
val_value_t * last_entry
last_entry based on target object; moves key leafs from last_keys into this value for checking in the...
Definition: getbulk.h:111
val_value_t * list_test_val
list_test filter for list-target
Definition: getbulk.h:99
obj_template_t * last_keys_obj
last_keys object saved from rpc/output for return last keys
Definition: getbulk.h:105
val_value_t * last_keys
last_keys anydata w/ last keys from client request
Definition: getbulk.h:96
val_value_t * ret_last_keys
last_keys anyxml w/ last keys to return to client
Definition: getbulk.h:114
val_value_t * fixed_keys
fixed_keys anydata w/ any fixed keys from client request
Definition: getbulk.h:102
struct cfg_template_t_ * source_cfg
back-ptr to the datastore config
Definition: getbulk.h:62
uint32 count
number of list entries requested
Definition: getbulk.h:71
restconf_content_t content_enum
content parameter from RESTCONF
Definition: getbulk.h:74
One YANG data-def-stmt.
Definition: obj.h:1229
one value to match one type
Definition: val.h:912
Value Node Basic Support.
YANG-API definitions (pre-RESTCONF)