Class in FIX Simple Binary Encoding (SBE)
SbeFieldV2
A message's or group entry's field, which uses an encoding at a place in its block and may state a constant.
classDiagram
class SbeFieldV2
click SbeFieldV2 href "../../classes/SbeFieldV2/"
SbeVersionedMixin <|-- SbeFieldV2
click SbeVersionedMixin href "../../classes/SbeVersionedMixin/"
SbeFieldV2 : alignment
SbeFieldV2 : deprecated_since
SbeFieldV2 : description
SbeFieldV2 : element_value
SbeFieldV2 : encoding_name
SbeFieldV2 : max_value
SbeFieldV2 : min_value
SbeFieldV2 : null_value
SbeFieldV2 : offset
SbeFieldV2 : presence
SbeFieldV2 --> "0..1" SbePresence : presence
click SbePresence href "../../enums/SbePresence/"
SbeFieldV2 : sbe_id
SbeFieldV2 : semantic_type
SbeFieldV2 : since_version
SbeFieldV2 : symbolic_name
SbeFieldV2 : value_ref
Inheritance#
- SbeFieldV2 [ SbeVersionedMixin]
Slots#
| Name | Cardinality and Range | Description | Inheritance |
|---|---|---|---|
| symbolic_name | 1 SbeSymbolicName | What the schema calls this element | direct |
| sbe_id | 1 Integer | The field’s FIX tag number | direct |
| encoding_name | 1 SbeSymbolicName | Which encoding this element uses, by name | direct |
| element_value | 0..1 SbeToken | The text of the XML element, which is the constant when presence is constant | direct |
| offset | 0..1 Integer | The octet this element starts at, counted from zero at the start of its block… | direct |
| alignment | 0..1 Integer | The multiple of octets the start of this field is placed on, in place of an o… | direct |
| presence | 0..1 SbePresence | Whether this element’s value is required, optional or constant | direct |
| null_value | 0..1 String | The value that stands for null in place of the primitive type’s default, writ… | direct |
| min_value | 0..1 String | The lowest value allowed, written as text | direct |
| max_value | 0..1 String | The highest value allowed, written as text | direct |
| value_ref | 0..1 SbeQualifiedName | The valid value that gives a constant element its value | direct |
| semantic_type | 0..1 SbeToken | The FIX datatype this field carries | direct |
| description | 0..1 String | Free text about this element, for the people who read the schema | direct |
| since_version | 0..1 Integer | The schema version that added this element | SbeVersionedMixin |
| deprecated_since | 0..1 Integer | The schema version that retired this element, which stays only for older appl… | SbeVersionedMixin |
Usages#
Rules#
A reference to a value needs a constant#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'value_ref': {'value_presence': 'PRESENT'}} | {'presence': {'equals_string': 'constant'}} |
A required value has no null#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'presence': {'equals_string': 'required'}} | {'null_value': {'value_presence': 'ABSENT'}} |
A constant has no null#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'presence': {'equals_string': 'constant'}} | {'null_value': {'value_presence': 'ABSENT'}} |
A constant has no lowest value#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'presence': {'equals_string': 'constant'}} | {'min_value': {'value_presence': 'ABSENT'}} |
A constant has no highest value#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'presence': {'equals_string': 'constant'}} | {'max_value': {'value_presence': 'ABSENT'}} |
An offset or an alignment, not both#
| Rule Applied | Preconditions | Postconditions | Elseconditions |
|---|---|---|---|
| slot_conditions | {'alignment': {'value_presence': 'PRESENT'}} | {'offset': {'value_presence': 'ABSENT'}} |
Comments#
- The mapping to an Orchestra field is close, not exact. This field has a place in one block, and FIX’s transposer carries one with a composite encoding to a component reference, not a field.
Identifier and Mapping Information#
Annotations#
| property | value |
|---|---|
| xsd_type | fieldType |
| xml_element | field |
Schema Source#
- from schema: https://w3id.org/lmodel/fix-sbe
Mappings#
| Mapping Type | Mapped Value |
|---|---|
| self | fix_sbe:SbeFieldV2 |
| native | fix_sbe:SbeFieldV2 |
| close | fix_orchestra:OrchestraFieldV10 |
LinkML Source#
Direct#
YAML
name: SbeFieldV2
annotations:
xsd_type:
tag: xsd_type
value: fieldType
xml_element:
tag: xml_element
value: field
description: A message's or group entry's field, which uses an encoding at a place
in its block and may state a constant.
comments:
- The mapping to an Orchestra field is close, not exact. This field has a place in
one block, and FIX's transposer carries one with a composite encoding to a component
reference, not a field.
from_schema: https://w3id.org/lmodel/fix-sbe
close_mappings:
- fix_orchestra:OrchestraFieldV10
mixins:
- SbeVersionedMixin
slots:
- symbolic_name
- sbe_id
- encoding_name
- element_value
- offset
- alignment
- presence
- null_value
- min_value
- max_value
- value_ref
- semantic_type
- description
slot_usage:
sbe_id:
name: sbe_id
description: The field's FIX tag number.
required: true
semantic_type:
name: semantic_type
description: The FIX datatype this field carries.
alignment:
name: alignment
description: The multiple of octets the start of this field is placed on, in place
of an offset.
rules:
- preconditions:
slot_conditions:
value_ref:
name: value_ref
value_presence: PRESENT
postconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
annotations:
sbe_section:
tag: sbe_section
value: '4: Field attributes'
description: A value_ref is valid only on an element whose presence is constant.
title: A reference to a value needs a constant
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: required
postconditions:
slot_conditions:
null_value:
name: null_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '4: Schema validation'
description: A null value cannot sit beside a presence of required.
title: A required value has no null
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
null_value:
name: null_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A null value cannot sit beside a presence of constant.
title: A constant has no null
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
min_value:
name: min_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A lowest value cannot sit beside a presence of constant.
title: A constant has no lowest value
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
max_value:
name: max_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A highest value cannot sit beside a presence of constant.
title: A constant has no highest value
- preconditions:
slot_conditions:
alignment:
name: alignment
value_presence: PRESENT
postconditions:
slot_conditions:
offset:
name: offset
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '3: Field byte alignment'
description: A field places itself by an offset or by an alignment, never both.
title: An offset or an alignment, not both
Induced#
YAML
name: SbeFieldV2
annotations:
xsd_type:
tag: xsd_type
value: fieldType
xml_element:
tag: xml_element
value: field
description: A message's or group entry's field, which uses an encoding at a place
in its block and may state a constant.
comments:
- The mapping to an Orchestra field is close, not exact. This field has a place in
one block, and FIX's transposer carries one with a composite encoding to a component
reference, not a field.
from_schema: https://w3id.org/lmodel/fix-sbe
close_mappings:
- fix_orchestra:OrchestraFieldV10
mixins:
- SbeVersionedMixin
slot_usage:
sbe_id:
name: sbe_id
description: The field's FIX tag number.
required: true
semantic_type:
name: semantic_type
description: The FIX datatype this field carries.
alignment:
name: alignment
description: The multiple of octets the start of this field is placed on, in place
of an offset.
attributes:
symbolic_name:
name: symbolic_name
description: What the schema calls this element.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- name
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeValidValue
- SbeChoice
- SbeMemberV1
- SbeBlockV1Mixin
- SbeFieldV1
- SbeElementV2
- SbeBlockV2Mixin
- SbeFieldV2
range: SbeSymbolicName
required: true
pattern: ^[A-Za-z_][0-9A-Za-z_]{0,63}$
sbe_id:
name: sbe_id
annotations:
xsd_type:
tag: xsd_type
value: xs:unsignedShort
description: The field's FIX tag number.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- id
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeMessageSchemaV1
- SbeBlockV1Mixin
- SbeFieldV1
- SbeMessageSchemaV2
- SbeBlockV2Mixin
- SbeFieldV2
range: integer
required: true
minimum_value: 0
maximum_value: 65535
encoding_name:
name: encoding_name
description: Which encoding this element uses, by name.
comments:
- It holds a name and not a class reference, because a name is unique only within
one schema document, where several documents may be listed side by side. tests/sbe_rules.py
checks that each names an encoding of its document.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- type
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeRefV1
- SbeFieldV1
- SbeRefV2
- SbeFieldV2
range: SbeSymbolicName
required: true
pattern: ^[A-Za-z_][0-9A-Za-z_]{0,63}$
element_value:
name: element_value
annotations:
xsd_type:
tag: xsd_type
value: xs:token
sbe_section:
tag: sbe_section
value: '4: Constant value'
description: The text of the XML element, which is the constant when presence
is constant.
from_schema: https://w3id.org/lmodel/fix-sbe
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeSimpleTypeV2
- SbeMemberTypeV2
- SbeFieldV2
range: SbeToken
pattern: ^\S+( \S+)*$
offset:
name: offset
annotations:
xsd_type:
tag: xsd_type
value: xs:unsignedInt
sbe_section:
tag: sbe_section
value: '3: Field offset specified by message schema'
description: The octet this element starts at, counted from zero at the start
of its block or composite.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- offset
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeMemberV1
- SbeFieldV1
- SbeMemberV2
- SbeFieldV2
range: integer
minimum_value: 0
maximum_value: 4294967295
alignment:
name: alignment
annotations:
xsd_type:
tag: xsd_type
value: xs:positiveInteger
sbe_section:
tag: sbe_section
value: '3: Field byte alignment'
description: The multiple of octets the start of this field is placed on, in place
of an offset.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- alignment
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeMemberV2
- SbeBlockV2Mixin
- SbeFieldV2
range: integer
minimum_value: 1
presence:
name: presence
description: Whether this element's value is required, optional or constant.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- presence
rank: 1000
ifabsent: string(required)
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeFieldV1
- SbeMemberTypeV2
- SbeFieldV2
range: SbePresence
null_value:
name: null_value
description: The value that stands for null in place of the primitive type's default,
written as text.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- nullValue
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeMemberTypeV2
- SbeFieldV2
range: string
min_value:
name: min_value
description: The lowest value allowed, written as text.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- minValue
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeMemberTypeV2
- SbeFieldV2
range: string
max_value:
name: max_value
description: The highest value allowed, written as text.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- maxValue
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeMemberTypeV2
- SbeFieldV2
range: string
value_ref:
name: value_ref
description: The valid value that gives a constant element its value.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- valueRef
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeSimpleTypeV1
- SbeFieldV1
- SbeMemberTypeV2
- SbeFieldV2
range: SbeQualifiedName
pattern: ^[A-Za-z_][0-9A-Za-z_]*\.[A-Za-z_][0-9A-Za-z_]*$
semantic_type:
name: semantic_type
annotations:
xsd_type:
tag: xsd_type
value: xs:token
description: The FIX datatype this field carries.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- semanticType
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeEncodingV1
- SbeBlockV1Mixin
- SbeFieldV1
- SbeBlockV2Mixin
- SbeFieldV2
range: SbeToken
pattern: ^\S+( \S+)*$
description:
name: description
description: Free text about this element, for the people who read the schema.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- description
rank: 1000
slot_uri: schema:description
owner: SbeFieldV2
domain_of:
- SbeValidValue
- SbeChoice
- SbeMessageSchemaV1
- SbeEncodingV1
- SbeBlockV1Mixin
- SbeFieldV1
- SbeMessageSchemaV2
- SbeEncodingSetV2
- SbeMessageSetV2
- SbeElementV2
- SbeBlockV2Mixin
- SbeFieldV2
range: string
since_version:
name: since_version
annotations:
xsd_type:
tag: xsd_type
value: xs:nonNegativeInteger
sbe_section:
tag: sbe_section
value: '5: Since version'
description: The schema version that added this element.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- sinceVersion
rank: 1000
ifabsent: int(0)
owner: SbeFieldV2
domain_of:
- SbeVersionedMixin
range: integer
minimum_value: 0
deprecated_since:
name: deprecated_since
annotations:
xsd_type:
tag: xsd_type
value: xs:nonNegativeInteger
sbe_section:
tag: sbe_section
value: '5: Deprecated elements'
description: The schema version that retired this element, which stays only for
older applications.
from_schema: https://w3id.org/lmodel/fix-sbe
aliases:
- deprecated
rank: 1000
owner: SbeFieldV2
domain_of:
- SbeVersionedMixin
range: integer
minimum_value: 0
rules:
- preconditions:
slot_conditions:
value_ref:
name: value_ref
value_presence: PRESENT
postconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
annotations:
sbe_section:
tag: sbe_section
value: '4: Field attributes'
description: A value_ref is valid only on an element whose presence is constant.
title: A reference to a value needs a constant
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: required
postconditions:
slot_conditions:
null_value:
name: null_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '4: Schema validation'
description: A null value cannot sit beside a presence of required.
title: A required value has no null
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
null_value:
name: null_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A null value cannot sit beside a presence of constant.
title: A constant has no null
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
min_value:
name: min_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A lowest value cannot sit beside a presence of constant.
title: A constant has no lowest value
- preconditions:
slot_conditions:
presence:
name: presence
equals_string: constant
postconditions:
slot_conditions:
max_value:
name: max_value
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '2: Common field schema attributes'
description: A highest value cannot sit beside a presence of constant.
title: A constant has no highest value
- preconditions:
slot_conditions:
alignment:
name: alignment
value_presence: PRESENT
postconditions:
slot_conditions:
offset:
name: offset
value_presence: ABSENT
annotations:
sbe_section:
tag: sbe_section
value: '3: Field byte alignment'
description: A field places itself by an offset or by an alignment, never both.
title: An offset or an alignment, not both