Functions | |
| void | ocs_mgmt_start_section (ocs_textbuf_t *textbuf, const char *name, int index) |
| Generate the beginning of a numbered section in a management XML document. More... | |
| void | ocs_mgmt_start_unnumbered_section (ocs_textbuf_t *textbuf, const char *name) |
| Generate the beginning of an unnumbered section in a management XML document. More... | |
| void | ocs_mgmt_end_unnumbered_section (ocs_textbuf_t *textbuf, const char *name) |
| Generate the end of a section in a management XML document. More... | |
| void | ocs_mgmt_end_section (ocs_textbuf_t *textbuf, const char *name, int index) |
| Generate the indexed end of a section in a management XML document. More... | |
| void | ocs_mgmt_emit_property_name (ocs_textbuf_t *textbuf, int mode, const char *name) |
| Generate a property, with no value, in a management XML document. More... | |
| void | ocs_mgmt_emit_string (ocs_textbuf_t *textbuf, int mode, const char *name, const char *value) |
| Generate a property with a string value in a management XML document. More... | |
| void | ocs_mgmt_emit_int (ocs_textbuf_t *textbuf, int mode, const char *name, const char *fmt,...) |
| Generate a property with an integer value in a management XML document. More... | |
| void | ocs_mgmt_emit_boolean (ocs_textbuf_t *textbuf, int mode, const char *name, int value) |
| Generate a property with a boolean value in a management XML document. More... | |
| void | ocs_mgmt_get_list (ocs_t *ocs, ocs_textbuf_t *textbuf) |
| Get a list of options supported by the driver. More... | |
| int | ocs_mgmt_get (ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) |
| Return the value of a management item. More... | |
| int | ocs_mgmt_set (ocs_t *ocs, char *name, char *value) |
| Set the value of a mgmt item. More... | |
| int | ocs_mgmt_exec (ocs_t *ocs, char *action, void *arg_in, uint32_t arg_in_length, void *arg_out, uint32_t arg_out_length) |
| Perform a management action. More... | |
| void ocs_mgmt_emit_boolean | ( | ocs_textbuf_t * | textbuf, |
| int | mode, | ||
| const char * | name, | ||
| int | value | ||
| ) |
Generate a property with a boolean value in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| mode | Defines whether the property is read(r)/write(w)/executable(x). |
| name | Name of the property. |
| value | Boolean value to be added to the textbuf. |
Definition at line 213 of file ocs_mgmt_common.c.
| void ocs_mgmt_emit_int | ( | ocs_textbuf_t * | textbuf, |
| int | mode, | ||
| const char * | name, | ||
| const char * | fmt, | ||
| ... | |||
| ) |
Generate a property with an integer value in a management XML document.
| textbuf | Pointer to driver dump text buffer. |
| mode | Defines whether the property is read(r)/write(w)/executable(x). |
| name | Name of the property. |
| fmt | A printf format for formatting the integer value. |
Definition at line 185 of file ocs_mgmt_common.c.
| void ocs_mgmt_emit_property_name | ( | ocs_textbuf_t * | textbuf, |
| int | mode, | ||
| const char * | name | ||
| ) |
Generate a property, with no value, in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| mode | Defines whether the property is read(r)/write(w)/executable(x). |
| name | Name of the property. |
Definition at line 143 of file ocs_mgmt_common.c.
| void ocs_mgmt_emit_string | ( | ocs_textbuf_t * | textbuf, |
| int | mode, | ||
| const char * | name, | ||
| const char * | value | ||
| ) |
Generate a property with a string value in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| mode | Defines whether the property is read(r)/write(w)/executable(x). |
| name | Name of the property. |
| value | Value of the property. |
Definition at line 164 of file ocs_mgmt_common.c.
| void ocs_mgmt_end_section | ( | ocs_textbuf_t * | textbuf, |
| const char * | name, | ||
| int | index | ||
| ) |
Generate the indexed end of a section in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| name | Name of the section. |
| index | Index number of this instance of the section. |
Definition at line 120 of file ocs_mgmt_common.c.
| void ocs_mgmt_end_unnumbered_section | ( | ocs_textbuf_t * | textbuf, |
| const char * | name | ||
| ) |
Generate the end of a section in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| name | Name of the section. |
Definition at line 100 of file ocs_mgmt_common.c.
| int ocs_mgmt_exec | ( | ocs_t * | ocs, |
| char * | action, | ||
| void * | arg_in, | ||
| uint32_t | arg_in_length, | ||
| void * | arg_out, | ||
| uint32_t | arg_out_length | ||
| ) |
Perform a management action.
In passing the request to other entities, the request is considered to be handled if the function returns 0.
| ocs | Pointer to the ocs structure. |
| action | Name of the action to be performed. |
| arg_in | Pointer to an argument being passed to the action. |
| arg_in_length | Length of the argument pointed to by arg_in. |
| arg_out | Pointer to an argument being passed to the action. |
| arg_out_length | Length of the argument pointed to by arg_out. |
Definition at line 538 of file ocs_mgmt.c.
| int ocs_mgmt_get | ( | ocs_t * | ocs, |
| char * | name, | ||
| ocs_textbuf_t * | textbuf | ||
| ) |
Return the value of a management item.
In passing the request to other entities, the request is considered to be answered when a response has been written into textbuf, indicated by textbuf->buffer_written being non-zero.
| ocs | Pointer to the ocs structure. |
| name | Name of the status item to be retrieved. |
| textbuf | Pointer to an ocs_textbuf, which is used to return the results. |
Definition at line 351 of file ocs_mgmt.c.
| void ocs_mgmt_get_list | ( | ocs_t * | ocs, |
| ocs_textbuf_t * | textbuf | ||
| ) |
Get a list of options supported by the driver.
| ocs | Pointer to the ocs structure. |
| textbuf | Pointer to an ocs_textbuf, which is used to accumulate the results. |
Definition at line 277 of file ocs_mgmt.c.
| int ocs_mgmt_set | ( | ocs_t * | ocs, |
| char * | name, | ||
| char * | value | ||
| ) |
Set the value of a mgmt item.
In passing the request to other entities, the request is considered to be handled if the function returns 0.
| ocs | Pointer to the ocs structure. |
| name | Name of the property to be changed. |
| value | Requested new value of the property. |
Definition at line 452 of file ocs_mgmt.c.
| void ocs_mgmt_start_section | ( | ocs_textbuf_t * | textbuf, |
| const char * | name, | ||
| int | index | ||
| ) |
Generate the beginning of a numbered section in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| name | Name of the section. |
| index | Index number of this instance of the section. |
Definition at line 61 of file ocs_mgmt_common.c.
| void ocs_mgmt_start_unnumbered_section | ( | ocs_textbuf_t * | textbuf, |
| const char * | name | ||
| ) |
Generate the beginning of an unnumbered section in a management XML document.
| textbuf | Pointer to the driver dump text buffer. |
| name | Name of the section. |
Definition at line 81 of file ocs_mgmt_common.c.