OpenTTCN/2.56.0/ANSI C SDK library reference/ISL/otSetProperty
From OpenTTCN
otSetProperty
The otSetProperty function sets an adapter property value that can be later inserted into conformance log in the form of a name-value pair.
int otSetProperty(
const char* name,
const char* value);
Parameters
|
name |
|
Property name. |
|
value |
|
Property value. |
Return values
Returns 0 upon success, non-zero upon failure.
Remarks
Passing "" or 0 in place of a property value has the semantics of removing the property binding for the specified name altogether if it was specified before; if it was not, no action is performed.
Adapter properties facilitate configuration management and reporting. Adapter properties are used merely as a means to insert user-defined name-value pairs into conformance log. Setting an adapter property has no other effect except enabling its reporting in conformance log.
Examples
Assume you have performed the following sequence of calls in your adapter initialization part:
otSetProperty("LLC version", "1.1.1");
otSetProperty("SAP bearer", "UH 2.5/E 2005");
Here is a portion of the corresponding conformance log example (adapter has TRI role):
Tester : {14:31:18.345} : // Time: 14:31:18.345. Date: 14/May/2008. MOT version: TC: 2.57.0.RC5.0; Adapter properties: TRI: LLC version=1.1.1;SAP bearer=UH 2.5/E 2005.
Requirements
|
Header |
<isl/TTCN3.h> |
|
Library |
openttcn-isl-mt.lib |
|
Compatibility |
OpenTTCN ANSI C SDK 2.x and higher |
