xpfDefineLongString
FUNCTION xpfDefineLongString(stringOrValueToBeString : GENERIC; options : INTEGER; attributeIdOrAttributeName : GENERIC; stringDelimiter : STRING; defaultStringForUnsetValue : STRING; integerAndInstancePrintFormat : STRING; stringPrefix : STRING; stringSuffix : STRING) longStringId : INTEGER;
Function to define/create an EDMlongString; An EDMlongString is a concept that is introduced to support the "string concatenation operation" on very long strings (some KB to several MB). Such operation will normally be relatively slow and result in fragmented virtual memory. The concept of EDMlongString improves the performance of such operations as well as avoid the fragmentation of virtual memory. This function may have variable number of arguments, i.e., it can be invoked with any number between 0 and 8 arguments.
Â
Arguments
1 | Type | Name | Comment |
2 | GENERIC | stringOrValueToBeString | Optional argument. Default value is INDETERMINATE (?). When specified, this argument defines the original string value of the defined EDMlongString. This argument may be a STRING, INTEGER or INSTANCE value. When the value is an INTEGER it will be transferred to a string by a "printf" operation. An INSTANCE value can be handled exactly like an INTEGER value, or by specifying an attributeName or attributeId, the actual instance attribute value will be used to make a string. The legal data types of such an attribute are STRING, INSTANCE and INTEGER. The actual attribute is specified in the "attributeIdOrAttributeName" argument. When an INTEGER or INSTANCE value is transferred to a string, the actual "format specification" can be specified in the "integerAndInstancePrintFormat" argument. The default for this "format specification" is "%lu"; |
3 | INTEGER | options | Optional argument. Default value is INDETERMINATE (?). All the available options are only valid when the actual value is an instance attribute value |
4 | GENERIC | attributeIdOrAttributeName | Optional argument. Default value is INDETERMINATE (?). Specifies an attribute of the instance specified as the "stringOrValueToBeString" argument in the xpfDefineLongString() or xpxAddToLongString() functions. The data type of the actual attribute must be STRING, INSTANCE or INTEGER; The "attributeIdOrAttributeName" can be specified by the attribute name or by the attributeId. |
5 | STRING | stringDelimiter | Optional argument. Default value is INDETERMINATE (?). Defines the delimiter string that is appended after each string that constitutes the EDMlongString. |
6 | STRING | defaultStringForUnsetValue | Optional argument. Default value is INDETERMINATE (?). Defines the string that will be the actual string value when the actual instance's attribute value is unset. |
7 | STRING | integerAndInstancePrintFormat | Optional argument. The defult value is "%lu". Defines the "format specification" used in the "printf" operation when the "stringOrValueToBeString" argument is an INSTANCE or an INTEGER. |
8 | STRING | stringPrefix | Optional argument. Default value is INDETERMINATE (?). This argument defines the prefix that will be prepended to all strings that constitutes the EDMlongString |
9 | STRING | stringSuffix | Optional argument. Default value is INDETERMINATE (?). This argument defines the suffix string that will be appended to all strings that constitutes the EDMlongString |
Return Value
Â
Type | Name | Comment |
INTEGER | longStringId | When the function is successfully performed, an INTEGER longStringId is returned. This longStringId can be used to identified the actual EDMlongString in other EDMlongString operations. When the function fails, INDETERMINATE (?) will be returned. Exception handling should be used to handle error conditions in the actual xpfDefineLongString() operation. |
Options
 | Option | Comment |
---|---|---|
1 | xpxSKIP_UNSET_VALUE | Instances with the actual attribute value unset will be skipped |
2 | xpxERROR_ON_UNSET_VALUE | The xpfDefineLongString() or xpxAddToLongString() functions will fail with an error condition when the actual instance's attribute value is unset. |
3 | xpxINSTANCEID_FOR_UNSET_VALUE | The actual instanceId (transferred to a string) will be used as the string when the actual instance's attribute value is unset. |
4 | xpxDELIMITER_FOR_UNSET_VALUE | The defined "stringDelimiter" value will be used as the string when the actual instance's attribute value is unset. |
5 | xpxSKIP_PREFIX_FOR_UNSET_VALUE | The defined "stringPrefix" will be skipped for unset attribute values |
6 | xpxSKIP_SUFFIX_FOR_UNSET_VALUE | The defined "stringSuffix" will be skipped for unset attribute values   |
Â
Example
<Missing Example>
Â
See also
Filter by label
There are no items with the selected labels at this time.
Â