oms_pr_attr_get()
Abstract
Obtains the value of an attribute for a registered process in the process registry.
Syntax
oms_pr_attr_get (pr_handle, attr_name, attr_type, attr_value_ptr)
| Argument | Type | Description |
|---|---|---|
pr_handle |
OmsT_Pr_Handle |
process registry process record handle for the process for which the attribute is being obtained. [A process registry process record handle may be obtained as a result of process discovery mechanism.] |
attr_name |
char * |
name of the attribute-of-interest. |
attr_type |
int |
data type of the attribute-of-interest (see Details). |
attr_value_ptr |
Vartype * |
pointer to the variable to be filled in with the value of the attribute-of-interest. |
Return Type
Compcode
Completion code indicating whether the value of the attribute-of-interest has been successfully obtained or not.
[This return code can be compared to constants OPC_COMPCODE_SUCCESS and OPC_COMPCODE_FAILURE to determine the outcome.]
Details
This procedure obtains the value of one attribute of a registered process. A failure code is returned if the attribute-of-interest does not exist for the process of interest.
The values for any of following attribute types can be obtained:
- OMSC_PR_OBJID
- OMSC_PR_STRING
- OMSC_PR_NUMBER
- OMSC_PR_STRINGLIST
- OMSC_PR_PROHANDLE
- OMSC_PR_ADDRESS
For more details on these attribute types, see Additional Attributes.