yumapro  20.10-12
YumaPro SDK
agt_ypgnmi_get.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018 - 2021, 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 #if defined(WITH_GNMI) && defined(WITH_RESTCONF) && defined(WITH_YCONTROL)
12 #ifndef _H_agt_ypgnmi_get
13 #define _H_agt_ypgnmi_get
14 
15 /* FILE: agt_ypgnmi_get.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 
34 date init comment
35 ----------------------------------------------------------------------
36 26-JUNE-18 am Begun
37 */
38 
39 #ifndef _H_ncxtypes
40 #include "ncxtypes.h"
41 #endif
42 
43 #ifndef _H_dlq
44 #include "dlq.h"
45 #endif
46 
47 #ifndef _H_status
48 #include "status.h"
49 #endif
50 
51 #ifdef __cplusplus
52 extern "C" {
53 #endif
54 
55 /********************************************************************
56 * *
57 * C O N S T A N T S *
58 * *
59 *********************************************************************/
60 
61 /********************************************************************
62 * *
63 * T Y P E S *
64 * *
65 *********************************************************************/
66 
67 
68 /********************************************************************
69 * *
70 * F U N C T I O N S *
71 * *
72 *********************************************************************/
73 
74 /* group defined in agt_ypgnmi.h */
75 
92 extern status_t
93  agt_ypgnmi_get_setup (ses_cb_t *scb,
94  rpc_msg_t *msg,
95  val_value_t *input_val);
96 
97 
98 
102 #ifdef __cplusplus
103 } /* end extern 'C' */
104 #endif
105 
106 #endif /* _H_agt_ypgnmi_get */
107 #endif // WITH_GNMI && WITH_RESTCONF && WITH_YCONTROL
ses.h
NETCONF Session Common definitions module.
xml_strlen
uint32 xml_strlen(const xmlChar *str)
Get the String len for xmlChar.
Definition: xml_util.c:1406
agt_restconf.h
IETF RESTCONF Protocol Message Handler.
agt_ses.h
Server Session Management.
xml_strdup
xmlChar * xml_strdup(const xmlChar *copyFrom)
String duplicate for xmlChar.
Definition: xml_util.c:1553
val_find_child
val_value_t * val_find_child(const val_value_t *parent, const xmlChar *modname, const xmlChar *childname)
Find the first instance of the specified child node.
Definition: val.c:8560
log_error
void log_error(const char *fstr,...) __attribute__((format(printf
Generate a new LOG_DEBUG_ERROR log entry.
agt_restconf_dispatch_gnmi_get
boolean agt_restconf_dispatch_gnmi_get(ses_cb_t *scb)
Dispatch an incoming gNMI GET request with help of RESTCONF.
Definition: agt_restconf.c:2785
val.h
Value Node Basic Support.
RESTCONF_CONTENT_ALL
@ RESTCONF_CONTENT_ALL
all descendant data nodes
Definition: yangapi.h:217
ncxconst.h
Contains NCX constants.
ncxmod.h
NCX Module Load Manager.
yangapi_new_rcb
yangapi_cb_t * yangapi_new_rcb(void)
Create a new YANG-API control block.
Definition: yangapi.c:317
agt_ypgnmi_get_setup
status_t agt_ypgnmi_get_setup(ses_cb_t *scb, rpc_msg_t *msg, val_value_t *input_val)
handle the YP-GNMI get request from the subsystem
Definition: agt_ypgnmi_get.c:272
SES_TYP_GNMI
@ SES_TYP_GNMI
RESTCONF over GNMI.
Definition: ses.h:325
ERR_NCX_MISSING_PARM
@ ERR_NCX_MISSING_PARM
233
Definition: status_enum.h:272
NO_ERR
@ NO_ERR
000
Definition: status_enum.h:188
agt_restcmn_entry_point
const xmlChar * agt_restcmn_entry_point(void)
Get the RESTCONF entry point name.
Definition: agt_restcmn.c:7482
ERR_NCX_OPERATION_FAILED
@ ERR_NCX_OPERATION_FAILED
274
Definition: status_enum.h:315
ypgnmi_free_gcb
void ypgnmi_free_gcb(ypgnmi_get_cb_t *cb)
Clean and free a ypgnmi_get_cb_t control block.
Definition: ypgnmi.c:113
ERR_NCX_INVALID_VALUE
@ ERR_NCX_INVALID_VALUE
258
Definition: status_enum.h:299
SES_TRANSPORT_GNMI
@ SES_TRANSPORT_GNMI
GNMI Internal processing over RESTCONF.
Definition: ses.h:347
ERR_INTERNAL_MEM
@ ERR_INTERNAL_MEM
003
Definition: status_enum.h:193
val_child.h
Value Node Child Access Support.
log_debug
void void void void void void void log_debug(const char *fstr,...) __attribute__((format(printf
Generate a new LOG_DEBUG_DEBUG log entry.
ypgnmi_new_gcb
ypgnmi_get_cb_t * ypgnmi_new_gcb(void)
Create a new ypgnmi_get_cb_t control block.
Definition: ypgnmi.c:90
typ.h
Parameter Type Handler.
NCX_CFGID_RUNNING
@ NCX_CFGID_RUNNING
running datastore (no value for not set!)
Definition: ncxtypes.h:384
agt.h
Multi-Protocol Network Management Server.
agt_restcmn.h
Common function for RESTCONF and YANG-API protocols.
EMPTY_STRING
#define EMPTY_STRING
empty string used to get const xmlChar * cast
Definition: ncxconst.h:289
tstamp_datetime
void tstamp_datetime(xmlChar *buff)
Set the current date and time in an XML dateTime string format.
Definition: tstamp.c:160
ycontrol_msg_cmn.h
YControl Message Utilities.
log.h
NCX System Logging Manager.
ncxtypes.h
YANG module data structures Many internal representations of YANG module constructs.
ypgnmi.h
YP-GNMI requests support module.
LOGDEBUG
#define LOGDEBUG
Check if at least log-level=debug.
Definition: log.h:287
cfg_rwlock_unlock
status_t cfg_rwlock_unlock(thd_tcb_t *tcb, cfg_template_t *cfg)
Release a lock associated with a cfg (datastore) RWLOCK structure.
Definition: cfg.c:535
agt_acm.h
NETCONF Server Access Control Entry Points.
xml_strcpy
uint32 xml_strcpy(xmlChar *copyTo, const xmlChar *copyFrom)
String copy for xmlChar.
Definition: xml_util.c:1486
yangapi_free_rcb
void yangapi_free_rcb(yangapi_cb_t *rcb)
Free a YANGAPI control block.
Definition: yangapi.c:351
VAL_OBJ
#define VAL_OBJ(V)
Access the object template.
Definition: val.h:381
ncx.h
YANG module utility functions.
obj.h
Data Object Support.
cfg_get_config_id
cfg_template_t * cfg_get_config_id(ncx_cfg_t cfgid)
Get the config struct from its ID.
Definition: cfg.c:1530
TSTAMP_MIN_SIZE
#define TSTAMP_MIN_SIZE
normal minimum buffer size for a tstamp buffer
Definition: tstamp.h:67
agt_ycontrol.h
Handle the YumaPro Control Protocol <ycontrol> (top-level) element.
VAL_STR
#define VAL_STR(V)
Access the value as a string ONLY if typ_is_string() is true.
Definition: val.h:464
xmlns.h
XML namespace support.
status.h
Global error messages for status code enumerations.
dlq.h
dlq provides general double-linked list and queue support:
agt_ypgnmi_get.h
YP-GNMI GET request support module.