ONLP
Open Network Linux Platform APIs
Data Structures | Typedefs | Functions

Data Structures

struct  onlp_generic_info_s
 Generic OID Information Structure. More...
 

Typedefs

typedef struct onlp_generic_info_s onlp_generic_info_t
 Generic OID Information Structure.
 

Functions

int onlp_generic_sw_init (void)
 Initialize the module software module. More...
 
int onlp_generic_hw_init (uint32_t flags)
 Initialize the module. More...
 
int onlp_generic_sw_denit (void)
 Deinitialize the generic software module. More...
 
int onlp_generic_hdr_get (onlp_oid_t oid, onlp_oid_hdr_t *hdr)
 Get the generic header structure. More...
 
int onlp_generic_info_get (onlp_oid_t oid, onlp_generic_info_t *info)
 Get the module info structure. More...
 
int onlp_generic_info_to_user_json (onlp_generic_info_t *info, cJSON **cj, uint32_t flags)
 Convert a generic info structure to user JSON. More...
 
int onlp_generic_info_to_json (onlp_generic_info_t *info, cJSON **cj, uint32_t flags)
 Convert a generic info structure to JSON. More...
 
int onlp_generic_info_from_json (cJSON *cj, onlp_generic_info_t *info)
 Convert a JSON object to a generic info structure. More...
 

Detailed Description

Function Documentation

◆ onlp_generic_hdr_get()

int onlp_generic_hdr_get ( onlp_oid_t  oid,
onlp_oid_hdr_t hdr 
)

Get the generic header structure.

Parameters
oidThe Generic oid.
[out]hdrReceives the header.

◆ onlp_generic_hw_init()

int onlp_generic_hw_init ( uint32_t  flags)

Initialize the module.

Parameters
flagsThe initialization flags.

◆ onlp_generic_info_from_json()

int onlp_generic_info_from_json ( cJSON *  cj,
onlp_generic_info_t info 
)

Convert a JSON object to a generic info structure.

Parameters
cjThe JSON object.
[out]infoReceives the generic info structure.

◆ onlp_generic_info_get()

int onlp_generic_info_get ( onlp_oid_t  oid,
onlp_generic_info_t info 
)

Get the module info structure.

Parameters
oidThe Generic oid.
[out]info

◆ onlp_generic_info_to_json()

int onlp_generic_info_to_json ( onlp_generic_info_t info,
cJSON **  cj,
uint32_t  flags 
)

Convert a generic info structure to JSON.

Parameters
infoThe generic info structure.
[out]cjReceives the JSON object.
flagsThe JSON format flags.

◆ onlp_generic_info_to_user_json()

int onlp_generic_info_to_user_json ( onlp_generic_info_t info,
cJSON **  cj,
uint32_t  flags 
)

Convert a generic info structure to user JSON.

Parameters
infoThe generic info structure.
[out]cjReceives the JSON object.
flagsThe JSON format flags.

◆ onlp_generic_sw_denit()

int onlp_generic_sw_denit ( void  )

Deinitialize the generic software module.

Note
The primary purpose of this API is to properly deallocate any resources used by the module in order faciliate detection of real resouce leaks.

◆ onlp_generic_sw_init()

int onlp_generic_sw_init ( void  )

Initialize the module software module.

Note
This will be called at software initialization time. This should not initialize any hardware.