|
Transformer SDK For C
8.0.9.562131-6357b6d3
|
![]() |
A set of fields makes up a data object or an update to an object. Standard record objects are made up of fields, whereas other types of data may store data in a different way.
Type: Function
Default: None
Defines a field number/name mapping.
Format:
add-field FieldName FieldNumber FieldFlags [FieldFlagsData]
| Name | Type | Default | Field Format |
| FieldName | string | [no default] | The name of the field |
| FieldNumber | integer | [no default] | The number of the field. This must be in the range -65535 to 65535. |
| FieldFlags | integer | 0 | The flags passed by the field. |
| FieldFlagsData | integer | -1 | Additional data (specifies the number of decimal places the field uses when FieldFlags is set to 256 or the type of field when FieldFlags is set to 512). |
| FieldFormat | integer | [none] | Defines the formatting of values added to this field. |
The table below shows the acceptable values of FieldFlags and the corresponding meanings of FieldFlagsData and FieldFormat. FieldFlags can be represent by either a text string or an integer.
These strings may be ORed together using the "|" operator to represent multiple flags: for example "type3|dp" means a field is type3 and uses the decimal point precision mode.
| FieldFlags (text) | FieldFlags (integer) | Description | FieldFlagsData | FieldFormat |
| type2 index | 1 | Identifies the field as a Type 2 index | Not Used | Not Used |
| type2 | 2 | Identifies the field as a Type 2 field | Not Used | Not Used |
| type3 | 4 | Identifies the field as a Type 3 field | Not Used | Not Used |
| dp decimal_precision | 256 | Decimal point precision mode | Number of decimal places | Not Used |
| fmt format | 512 | Format mode | Field type | Format string (eg "%%.12g") |
| fmt_id format_id/td> | 1024 | Format set mode | Not Used | Name of format set as specified using add-field-format |
The table below lists the field types that can be used in FieldsFlagsData when in Format mode (FieldFlags = 512)
| Type | Description |
| 1 | 32 bit float |
| 2 | 64 bit float |
| 3 | 8 bit integer |
| 4 | 16 bit integer |
| 5 | 32 bit integer |
| 6 | 64 bit integer |
| 7 | 8 bit unsigned integer |
| 8 | 16 bit unsigned integer |
| 9 | 32 bit unsigned integer |
| 10 | 64 bit unsigned integer |
Type: String
Default: %.8g
Format for float32 types
Type: String
Default: %.12g
Format for float64 types
Type: String
Default: %hhd
Format for int8 types
Type: String
Default: %hd
Format for int16 types
Type: String
Default: %d
Format for int32 types
Type: String
Default: %lld
Format for int64 types
Type: String
Default: %hhu
Format for uint8 types
Type: String
Default: %hu
Format for uint16 types
Type: String
Default: %u
Format for uint32 types
Type: String
Default: %llu
Format for uint64 types
add-field-formatThis option defines sets of format strings which can be used by the add-field option.
Format:
add-format
name [value]
float32-fmt [value]
float64-fmt [value]
int8-fmt [value]
int16-fmt [value]
int32-fmt [value]
int64-fmt [value]
uint8-fmt [value]
uint16-fmt [value]
uint32-fmt [value]
uint64-fmt [value]
end format
Type: String
Default: None
Name of this format set
Type: String
Default: None
Format string for 32 bit floats
Type: String
Default: None
Format string for 64 bit floats
Type: String
Default: None
Format string for 8 bit integers
Type: String
Default: None
Format string for 16 bit integers
Type: String
Default: None
Format string for 32 bit integers
Type: String
Default: None
Format string for 64 bit integers
Type: String
Default: None
Format string for 8 bit unsigned integers
Type: String
Default: None
Format string for 16 bit unsigned integers
Type: String
Default: None
Format string for 32 bit unsigned integers
Type: String
Default: None
Format string for 64 bit unsigned integers
Type: String
Default: None
Locale for numeric field formatting