# DeviceResourceIface ## **Overview** **Related Modules:** [DriverConfig](DriverConfig.md) **Description:** Provides functions for obtaining information about the device resource configuration tree. This structure provides functions for obtaining information about the device resource configuration tree, including the root node, the **unit** attribute data, and the **String** attribute data. **Since:** 1.0 **Version:** 1.0 ## **Summary** ## Data Fields
GetRootNode )(void) |
const struct DeviceResourceNode *(* |
GetBool )(const struct DeviceResourceNode *node, const char *attrName) |
Obtains the value of a BOOL attribute of a configuration tree node. |
GetUint8 )(const struct DeviceResourceNode *node, const char *attrName, uint8_t *value, uint8_t def) |
Obtains the value of a Uint8 attribute of a configuration tree node. |
GetUint8ArrayElem )(const struct DeviceResourceNode *node, const char *attrName, uint32_t index, uint8_t *value, uint8_t def) |
Obtains the value of a Unit8 array attribute numbered index of a configuration tree node. |
GetUint8Array )(const struct DeviceResourceNode *node, const char *attrName, uint8_t *value, uint32_t len, uint8_t def) |
Obtains the values of a Uint8 array attribute of a configuration tree node. |
GetUint16 )(const struct DeviceResourceNode *node, const char *attrName, uint16_t *value, uint16_t def) |
Obtains the value of a Uint16 attribute of a configuration tree node. |
GetUint16ArrayElem )(const struct DeviceResourceNode *node, const char *attrName, uint32_t index, uint16_t *value, uint16_t def) |
Obtains the value of a Uint16 array attribute numbered index of a configuration tree node. |
GetUint16Array )(const struct DeviceResourceNode *node, const char *attrName, uint16_t *value, uint32_t len, uint16_t def) |
Obtains the values of a Uint16 array attribute of a configuration tree node. |
GetUint32 )(const struct DeviceResourceNode *node, const char *attrName, uint32_t *value, uint32_t def) |
Obtains the value of a Uint32 attribute of a configuration tree node. |
GetUint32ArrayElem )(const struct DeviceResourceNode *node, const char *attrName, uint32_t index, uint32_t *value, uint32_t def) |
Obtains the value of a Uint32 array attribute numbered index of a configuration tree node. |
GetUint32Array )(const struct DeviceResourceNode *node, const char *attrName, uint32_t *value, uint32_t len, uint32_t def) |
Obtains the values of a Uint32 array attribute of a configuration tree node. |
GetUint64 )(const struct DeviceResourceNode *node, const char *attrName, uint64_t *value, uint64_t def) |
Obtains the value of a Uint64 attribute of a configuration tree node. |
GetUint64ArrayElem )(const struct DeviceResourceNode *node, const char *attrName, uint32_t index, uint64_t *value, uint64_t def) |
Obtains the value of a Uint64 array attribute numbered index of a configuration tree node. |
GetUint64Array )(const struct DeviceResourceNode *node, const char *attrName, uint64_t *value, uint32_t len, uint64_t def) |
Obtains the values of a Uint64 array attribute of a configuration tree node. |
GetString )(const struct DeviceResourceNode *node, const char *attrName, const char **value, const char *def) |
Obtains the value of a String attribute of a configuration tree node. |
GetStringArrayElem )(const struct DeviceResourceNode *node, const char *attrName, uint32_t index, const char **value, const char *def) |
Obtains the value of a String array attribute numbered index of a configuration tree node. |
GetElemNum )(const struct DeviceResourceNode *node, const char *attrName) |
Obtains the number of values for an array attribute of a configuration tree node. |
GetNodeByMatchAttr )(const struct DeviceResourceNode *node, const char *attrValue) |
const struct DeviceResourceNode *(* Obtains a specified child node of the current tree node based on the value of a specific reserved attribute (for example, the reserved attribute of the HCS is match_attr). |
GetChildNode )(const struct DeviceResourceNode *node, const char *nodeName) |
const struct DeviceResourceNode *(* Obtains the child node with a specified node name from a parent node. |
GetNodeByRefAttr )(const struct DeviceResourceNode *node, const char *attrName) |
const struct DeviceResourceNode *(* Obtains the node that is specified by a node-type attribute of a configuration tree node. |
node | Indicates the pointer to the configuration tree node. |
attrName | Indicates the pointer to the name of the attribute. |
node | Indicates the pointer to the parent node. |
nodeName | Indicates the pointer to the name of the child node to obtain. |
node | Indicates the pointer to the configuration tree node. |
attrName | Indicates the pointer to the name of the array attribute. |
node | Indicates the pointer to the node for whom a child node is to be obtained. The node can be the child node's parent node or grandparent node. |
attrValue | Indicates the pointer to the value of the reserved attribute configured for the child node. |
node | Indicates the pointer to the tree node whose attribute is to obtain. |
attrName | Indicates the pointer to the name of attribute whose value is a node path. |