yumapro  24.10-2
YumaPro SDK
Loading...
Searching...
No Matches
agt_hook_util.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_agt_hook_util
13#define _H_agt_hook_util
14
15/* FILE: agt_hook_util.h
16*********************************************************************
17* *
18* P U R P O S E *
19* *
20*********************************************************************/
21
28/*********************************************************************
29* *
30* C H A N G E H I S T O R Y *
31* *
32*********************************************************************
33
34date init comment
35----------------------------------------------------------------------
3604-jan-16 ma Begun
37
38
39*********************************************************************
40* *
41* I N C L U D E F I L E S *
42* *
43*********************************************************************/
44#ifndef _H_status
45#include "status.h"
46#endif
47
48#ifdef __cplusplus
49extern "C" {
50#endif
51
52
94/********************************************************************
95* *
96* T Y P E S *
97* *
98*********************************************************************/
99
101typedef enum agt_hook_fmt_t_ {
106
107
108/********************************************************************
109* *
110* F U N C T I O N S *
111* *
112*********************************************************************/
113
114
121extern boolean
123
124
131extern boolean
133
134
141extern const xmlChar *
143
144
151extern agt_hook_type_t
152 agt_hook_get_type_enum (const xmlChar *type);
153
154
161extern const xmlChar *
163
164
171extern agt_hook_fmt_t
172 agt_hook_get_format_enum (const xmlChar *format);
173
174
184extern status_t
186 agt_hook_fmt_t format,
187 agt_hook_type_t type,
188 const xmlChar *defpath);
189
190
200extern status_t
202 const xmlChar *defpath);
203
204
212extern status_t
214 const xmlChar *defpath);
215
216
224extern boolean
226
227
235extern boolean
237
238
246extern boolean
248
249
257extern boolean
259
260
268extern boolean
270
271
272#ifdef WITH_YCONTROL
281extern status_t
282 agt_hook_post_sethook_subsys_register (const xmlChar *subsys_id,
283 const xmlChar *defpath);
284
285
296extern status_t
297 agt_hook_hooks_subsys_register (const xmlChar *subsys_id,
298 const xmlChar *defpath,
299 agt_hook_fmt_t format,
300 agt_hook_type_t type);
301#endif // WITH_YCONTROL
302
303
307#ifdef __cplusplus
308} /* end extern 'C' */
309#endif
310
311#endif // _H_agt_hook_util
status_t agt_hook_order_obj_ok(obj_template_t *obj, const xmlChar *defpath)
Check if format of the callback is acceptable for the object.
Definition: agt_hook_util.c:396
status_t agt_hook_post_sethook_subsys_register(const xmlChar *subsys_id, const xmlChar *defpath)
Register an object specific SIL-SA Post Set Hook callback function.
Definition: agt_hook_util.c:689
boolean agt_hook_type_valid(agt_hook_type_t type)
Verify that the hook TYPE is valid.
Definition: agt_hook_util.c:155
boolean agt_hooks_callback_set(obj_template_t *obj)
Check if an any Hook callback is registered for this object for SIL-SA usage.
Definition: agt_hook_util.c:499
const xmlChar * agt_hook_get_format_name(agt_hook_fmt_t format)
Get the keyword for the specified agt_hook_fmt_t enumeration.
Definition: agt_hook_util.c:280
agt_hook_fmt_t
different hook formats dictates specific hook functionality
Definition: agt_hook_util.h:101
boolean agt_hook_fmt_valid(agt_hook_fmt_t format)
Verify that the hook format is valid.
Definition: agt_hook_util.c:191
status_t agt_hook_obj_ok(obj_template_t *obj, agt_hook_fmt_t format, agt_hook_type_t type, const xmlChar *defpath)
Check if format of the callback is acceptable for the object.
Definition: agt_hook_util.c:336
agt_hook_type_t agt_hook_get_type_enum(const xmlChar *type)
Get agt_hook_fmt_t enumeration structure from specified string.
Definition: agt_hook_util.c:251
boolean agt_hook_subtree_format(obj_template_t *obj)
Check if an Transaction Hook callback is registered for this object for SIL-SA usage.
Definition: agt_hook_util.c:645
agt_hook_fmt_t agt_hook_get_format_enum(const xmlChar *format)
Get agt_hook_fmt_t enumeration structure from specified string.
Definition: agt_hook_util.c:307
status_t agt_hook_hooks_subsys_register(const xmlChar *subsys_id, const xmlChar *defpath, agt_hook_fmt_t format, agt_hook_type_t type)
Register an object specific SIL-SA Post Set Hook callback function.
Definition: agt_hook_util.c:786
status_t agt_hook_post_sethook_obj_ok(obj_template_t *obj, const xmlChar *defpath)
Check if format of the callback is acceptable for the object.
Definition: agt_hook_util.c:445
const xmlChar * agt_hook_get_type_name(agt_hook_type_t type)
Get the keyword for the specified agt_hook_type_t enumeration.
Definition: agt_hook_util.c:222
boolean agt_txhook_callback_set(obj_template_t *obj)
Check if an Transaction Hook callback is registered for this object for SIL-SA usage.
Definition: agt_hook_util.c:609
boolean agt_sethook_callback_set(obj_template_t *obj)
Check if an Set Hook callback is registered for this object for SIL-SA usage.
Definition: agt_hook_util.c:573
boolean agt_post_sethook_callback_set(obj_template_t *obj)
Check if an Post Set Hook callback is registered for this object for SIL-SA usage.
Definition: agt_hook_util.c:537
@ AGT_HOOKFMT_NODE
node mode
Definition: agt_hook_util.h:104
@ AGT_HOOKFMT_SUBTREE
subtree mode
Definition: agt_hook_util.h:103
@ AGT_HOOKFMT_NONE
not set
Definition: agt_hook_util.h:102
agt_hook_type_t
Hook types enumeration to specify Hook type.
Definition: agt.h:817
status_t
global error return code
Definition: status_enum.h:210
Global error messages for status code enumerations.
One YANG data-def-stmt.
Definition: obj.h:1229