Broker 10.5 | webMethods Broker Documentation | webMethods Broker Client C API Programmer's Guide | API Reference | awSet | awSetSequenceField
BrokerError awSetSequenceField(
BrokerEvent event,
char *field_name,
short field_type,
int src_offsetint dest_offset,
int n,
void *source_values);
The event whose sequence field is to be set.
Name of the event sequence field.
A field type, such as FIELD_TYPE_BOOLEAN, defined in <awetdef.h>.
The number of elements to skip from the beginning of the source sequence.
The number of elements to skip from the beginning of the destination sequence.
Number of elements in the source sequence.
An array of source values to use. See awSet<type>SeqField for the appropriate types.
Sets the values of the destination sequence field field_name to the values contained in the source sequence source_values. The elements in the source and destination sequence are of the type represented by field_type.
A sequence of sequences cannot be set with this function.
This function may overwrite all or part of the destination sequence field or cause the destination sequence to grow, if a larger number of elements are stored into the sequence. This function never reduces the number of elements in the destination sequence: You must use awSetSequenceFieldSize function to reduce the size of a sequence.
If you set five elements (a, b, c, d, e) into a sequence at location 0, the sequence would appear as: [a b c d e]. If you then set three elements (1, 2, 3) into this same sequence at location 0, the sequence would then appear as follows:
[1 2 3 d e]
Attempting to set an event field with a type that does not match the event's definition will result in an error being returned. No error will be returned if FIELD_TYPE_STRING values are used to set a sequence field whose type is FIELD_TYPE_UNICODE_STRING. In these cases, the ANSI strings that are supplied will automatically be converted to unicode strings.
See Specifying Field Names for complete information on specifying field_name.
Possible BrokerError major codes
The event is associated with a Broker client and field_name does not exist in the event.
The field's type does not match the type of field_type or the field_name incorrectly accesses a type.
The event is invalid.
The field_name is invalid.
The field_type is FIELD_TYPE_SEQUENCE or is not a supported field type.
The parameter field_name or source_value is NULL.
The src_offset is out of range, the dest_offset is less than zero, or n is less than -1.
See also: