yumapro  25.10-3
YumaPro SDK
Loading...
Searching...
No Matches
sid_file.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2021 - 2025, 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#ifndef _H_sid_file
12#define _H_sid_file
13
14#ifdef WITH_YANG_CBOR
15
16/* FILE: sid_file.h
17*********************************************************************
18* *
19* P U R P O S E *
20* *
21*********************************************************************/
22
29/*********************************************************************
30* *
31* C H A N G E H I S T O R Y *
32* *
33*********************************************************************
34
35date init comment
36----------------------------------------------------------------------
3726-nov-21 abb Begun; start from yang_hash.c
38
39*/
40
41#include "status_enum.h"
42#include "obj.h"
43
44/*** assumes procdefs.h has been included ***/
45
46#ifdef __cplusplus
47extern "C" {
48#endif
49
50/********************************************************************
51* *
52* T Y P E S *
53* *
54*********************************************************************/
55
56
57/********************************************************************
58* *
59* F U N C T I O N S *
60* *
61*********************************************************************/
62
63/* Group definied in yang.h */
64
65
82extern status_t sid_file_init (void);
83
84
89extern void sid_file_cleanup (void);
90
91
104extern val_value_t *
106 status_t *res);
107
108
125extern val_value_t *
127 const xmlChar *parmstr,
128 boolean is_date,
129 status_t *res);
130
131
154extern status_t
155 sid_file_apply (uint32 sid_tree_id,
156 val_value_t *sidfile,
157 ncx_module_t *mod,
158 boolean internal,
159 boolean update_mode);
160
161
167extern obj_template_t *
168 sid_file_get_obj (void);
169
170
184extern status_t
186 dlq_hdr_t *sid_rangeQ,
187 uint32 *total);
188
189
190
204extern status_t
205 sid_file_add_range (ncx_sid_t range_start,
206 uint32 range_size,
207 dlq_hdr_t *sid_rangeQ);
208
209
210
229extern status_t
230 sid_file_check_ranges (ncx_sid_t sid,
231 dlq_hdr_t *sid_rangeQ,
232 boolean set_highest,
233 ncx_sid_range_t **ret_range);
234
235
236
249extern status_t
250 sid_file_verify_ranges (dlq_hdr_t *sid_rangeQ);
251
252
255#endif // WITH_YANG_CBOR
256
257#ifdef __cplusplus
258} /* end extern 'C' */
259#endif
260
261#endif /* _H_sid_file */
status_t
global error return code
Definition: status_enum.h:219
val_value_t * sid_file_load(ncx_module_t *mod, status_t *res)
Load the SID file for the specified YANG module.
Definition: sid_file.c:769
obj_template_t * sid_file_get_obj(void)
Get the OBJ template for the SID file.
Definition: sid_file.c:859
status_t sid_file_apply(uint32 sid_tree_id, val_value_t *sidfile, ncx_module_t *mod, boolean internal, boolean update_mode)
Apply the SID file contents to specified YANG module.
Definition: sid_file.c:800
status_t sid_file_add_range(ncx_sid_t range_start, uint32 range_size, dlq_hdr_t *sid_rangeQ)
Add a specified range struct to the end of the sid_rangeQ.
Definition: sid_file.c:972
val_value_t * sid_file_load_update(ncx_module_t *mod, const xmlChar *parmstr, boolean is_date, status_t *res)
Load the SID file for the specified YANG module.
Definition: sid_file.c:737
status_t sid_file_get_ranges(val_value_t *sidfile, dlq_hdr_t *sid_rangeQ, uint32 *total)
Get the assignment ranges from the SID file val_value_t.
Definition: sid_file.c:906
void sid_file_cleanup(void)
Cleanup the SID FIle Parser Module.
Definition: sid_file.c:531
status_t sid_file_check_ranges(ncx_sid_t sid, dlq_hdr_t *sid_rangeQ, boolean set_highest, ncx_sid_range_t **ret_range)
Check if a SID value is in range.
Definition: sid_file.c:1011
status_t sid_file_init(void)
Initialize the SID FIle Parser Module.
Definition: sid_file.c:480
status_t sid_file_verify_ranges(dlq_hdr_t *sid_rangeQ)
Verify that all the SID ranges are separate and do not overlap.
Definition: sid_file.c:1054
Data Object Support.
global error status code enumerations
representation of one module or submodule during and after parsing
Definition: ncxtypes.h:1180
YANG SID assignment range struct.
Definition: ncxtypes.h:781
One YANG data-def-stmt.
Definition: obj.h:1284
one value to match one type
Definition: val.h:1024