flync_4_someip¶
SOME/IP Configuration¶
Note
Any SOME/IP related configuration such as service descriptions or timings profiles are placed in the directory 📁 general/someip/.
This is a non-mandatory directory for the FLYNC configuration.
- class SOMEIPConfig¶
Bases:
FLYNCBaseModelBasic configuration of SOME/IP for a target system.
Parameters¶
- version: Literal[ “1.0” ]
The version of this config.
- services: list[
SOMEIPServiceInterface] List of SOME/IP Services.
- sd_config:
SDConfig Configuration of the Service-Discovery.
Service Discovery¶
- class SDConfig¶
Bases:
FLYNCBaseModelallows to configure the SOME/IP Service-Discovery. Represent from the Chapter SD, the Endpoint and SD Endpoint.
Parameters¶
- ip_address
IPvAnyAddress IP on which the service discovery operates.
- portint
Port which the service discovery operates on. Must be greater than 0 and lower than 0xFFFF.
- sd_timingsList[
SDTimings] Timing Configurations for SOME/IP-SD.
- ip_address
- class SDTimings¶
Bases:
DictInstancesConfigurations for SOME/IP-SD Timings.
Parameters¶
- profile_idstr
A unique ID for the SOME/IP-SD timings profile.
- initial_delay_minint
Initial delay in milliseconds: This parameter keeps back service offers to pack more entries together. Must be greater or equal to 0. Defaults to 10.
- initial_delay_maxint
Initial delay in milliseconds: This parameter keeps back service offers to pack more entries together. Must be greater or equal to 0. Defaults to 10.
- repetitions_base_delayint
Repetitions Base delay in milliseconds: This parameter helps in fast startup and to make startup more robust. Loss of the first offer results in this delay. Must be greater or equal to 0. Defaults to 30.
- repetitions_maxint
Number of repetitions while doubling delay. Must be greater or equal to 0. Defaults to 3.
- request_response_delay_minint
Request response delay in milliseconds: This parameter keeps back subscribes to pack more entries together. Must be greater or equal to 0. Defaults to 10.
- request_response_delay_maxint
Request response delay in milliseconds: This parameter keeps back subscribes to pack more entries together.”, Must be greater or equal to 0. Defaults to 10.
- offer_cyclic_delay: int, optional
Offer cyclic delay in milliseconds: This parameter keeps system alive with cyclic offer. Must be greater or equal to 0. Defaults to 1000.
- offer_ttlint, optional
Time to live in milliseconds: This parameter determines how fast to age out state. Must be greater or equal to 0. Defaults to 3000.
- find_ttlint, optional
Offer cyclic delay in milliseconds: This parameter keeps system alive with cyclic offer. Must be greater or equal to 0. Defaults to 1000.
- subscribe_ttl: int, optional
Time to live in milliseconds: This parameter determines how fast to age out state. Must be greater or equal to 0. Defaults to 3.
Service Interface¶
- class SOMEIPServiceInterface¶
Bases:
DictInstancesClass to create a SOME/IP service interface definition.
Parameters¶
- namestr
Name of the service
description : str, optional
- idint
Unique identifier for the service. Must be greater than 0 and lower or equal than 0xFFFF.
- major_versionint
The major version of this service interface. Must be greater than 0 and lower or equal than 0xFF.
- minor_versionint
The minor version of this service interface. Must be greater than 0 and lower or equal than 0xFFFFFFFF.
- fieldsList[
SOMEIPField] Fields of the service.
- eventsList[
SOMEIPEvent] Events of the service.
- eventgroupsList[
SOMEIPEventgroup] Eventgroups of the service.
- methodsList[
SOMEIPFireAndForgetMethod|SOMEIPRequestResponseMethod] Methods of the service.
- meta
SOMEIPServiceMetadata Metadata for the SOME/IP Service.
- class SOMEIPParameter¶
Bases:
FLYNCBaseModelDefinition of Parameters for SOME/IP.
Parameters¶
- namestr
Identifies the parameter.
- descriptionstr, optional
Human-readable description of the datatype.
- type
AllTypes Datatype of the Parameter.
Method¶
- class SOMEIPMethod¶
Bases:
FLYNCBaseModelDatastructure to model SOME/IP methods.
Parameters¶
- namestr
Name of the Method.
- descriptionstr, optional
Description of the Method.
- typeLiteral[“request_response”, “fire_and_forget”]
Type of the Method.
- idint
Unique method identifier for the service interface. Must be greater than 0 and lower or equal than 0xFFFF.
- reliablebool
Indicates whether the event is transmitted reliably.
- someip_tp
SOMEIPTP SOME/IP Transport Protocol configuration for this method.
- input_parameterslist[
SOMEIPParameters] The parameters of the Request
- someip_timingstr, optional
Name of the timings definition. Defaults to “method_default”.
- class SOMEIPFireAndForgetMethod¶
Bases:
SOMEIPMethodAllows to model SOME/IP methods which will not return a response.
- class SOMEIPRequestResponseMethod¶
Bases:
SOMEIPMethodAllows to model SOME/IP methods which will return a response.
Parameters¶
- output_parameterslist[
SOMEIPParameters], optional The parameters of the Response
- output_parameterslist[
- class SOMEIPTP¶
Bases:
FLYNCBaseModelSOME/IP Transport Protocol configuration.
Parameters¶
- enabledbool
Indicates whether SOME/IP-TP is enabled or not. Defaults to False.
- max_segment_lengthint
maximum segment length. Defaults to 0.
Eventgroup¶
- class SOMEIPEventgroup¶
Bases:
FLYNCBaseModelMain datastructure to model a SOME/IP Eventgroup.
Parameters¶
- namestr
Name of the Eventgroup.
description : str, optional
- idint
Identifies the Eventgroup. Must be greater than 0 and lower or equal than 0xFFFF.
- multicast_thresholdint, optional
Identifies the multicast threshold. Must be greater than 0. Defaults to 0.
- events: list[
SOMEIPEvent|SOMEIPField] The events and fields this eventgroup contains.
Event¶
- class SOMEIPEvent¶
Bases:
DictInstancesDefines a SOME/IP event definition.
This model is used to describe a SOME/IP event, including its identifier, reliability settings, optional E2E protection configuration, and the list of parameters that the event transports.
Parameters¶
- namestr
Name of the event.
- descriptionstr, optional
Human-readable description of the event.
- idint
Unique identifier of the event. Must be greater than 0 and lower or equal than 0xFFFF.
- reliablebool
Indicates whether the event is transmitted reliably.
- e2e
E2EConfig, optional E2E configuration for the event.
- parameters list[
SOMEIPParameters] Parameters of the event
- someip_timingstr, optional
Name of the timings definition. Defaults to “event_default”.
Field¶
- class SOMEIPField¶
Bases:
FLYNCBaseModelBase datastructure to design a SOME/IP Field
Parameters¶
- namestr
Name of the Field.
- parameters list[
SOMEIPParameters] List of Parameters of the Field.
- descriptionstr, optional
Description of the Field.
- notifier_idint, optional
Identifies the Field Notifier. Must be greater than 0 and lower or equal than 0xFFFF. Defaults to 1.
- setter_idint, optional
Identifies the Field Setter. Must be greater than 0 and lower or equal than 0xFFFF.
- getter_idint, optional
Identifies the Field Getter. Must be greater than 0 and lower or equal than 0xFFFF.
- reliablebool
Indicates whether the event is transmitted reliably.
- notifier_e2e
E2EConfig, optional E2E configuration for the field notifier.
- someip_timingstr, optional
Name of the timing definition. Defaults to “field_default”.
Service Deployment¶
Hint
Service Deployments are directly configured in a socket. For further details on the configuration go to: Socket Config.
- class SOMEIPServiceProvider¶
Bases:
SOMEIPServiceDeploymentDefines the provider of a SOME/IP service instance (like offering & sending responses, events).
Parameters¶
deployment_type : Literal[“someip_provider”]
- major_versionint
The major version of this service interface. Must be greater than 0 and less than 255.
- minor_versionint
The minor version of this service interface. Must be greater than 0 and less than 0xFFFFFFFF.
- provided_eventgroupsList[str], optional
If set, only the named eventgroups are offered/sent on this socket. None means all eventgroups of the service are provided.
- class SOMEIPServiceConsumer¶
Bases:
SOMEIPServiceDeploymentDefines the consumer of a SOME/IP service instance (like subscribing & calling methods).
Parameters¶
deployment_type : Literal[“someip_consumer”]
- major_versionint
The major version of this service interface. Must be greater than 0 and less or equal 255.
consumed_eventgroups : List[str], optional
- class SOMEIPSDDeployment¶
Bases:
FLYNCBaseModelDefines the Service Discovery endpoint of SOME/IP.
Parameters¶
deployment_type: Literal[“someip_sd”]
- multicastOptional[
MulticastSDEndpoint] Multicast configuration for an SD endpoint.
- multicastOptional[
- class Layer4Endpoint¶
Bases:
FLYNCBaseModelLayer4Endpoint Class method for Layer4 endpoint .
Parameters¶
- protocolLiteral[“UDP”, “TCP”]
Protocol of the Layer4Endpoint. Defaults to UDP.
- portint
Layer4 Port. Must be greater than 0 and less or equal to 65535.
- class MulticastEndpoint¶
Bases:
BaseUDPDeploymentMulticastEndpoint for UDP Deployments.
Parameters¶
- ip_addressIPvAnyAddress
IP-Address of the Multicast Endpoint.
- class MulticastSDEndpoint¶
Bases:
MulticastEndpointMulticastSDEndpoint
Parameters¶
- ip_ttlint
IP Time-to-Live. Must be greater or equal to 0 and less or equal to 255.
- class SOMEIPServiceDeployment¶
Bases:
ABC,FLYNCBaseModelSOMEIPServiceDeployment Create a service deployment that will be used for provided service.
Parameters¶
deployment_type : Literal[“someip”]
- serviceint
Identifies the service. Must be greater than 0 and less than 0xFFFF.
- major_versionint
The major version of this service interface. Must be greater than 0 and less or equal 255.
- instance_id: int
Id of the Service Instance. Must be greater than 0 and less than 0xFFFF.
- someip_sd_timings_profile: str
The SOME/IP timings profile_id used for the deployment.
- class BaseUDPDeployment¶
Bases:
Layer4EndpointBase class for deploying a SOME/IP service onto a UDP-endpoint.
- class UDPDeployment¶
Bases:
BaseUDPDeploymentAllows deploying a SOME/IP service onto a UDP-endpoint (including multicast).
Parameters¶
- multicast
MulticastEndpoint, optional Multicast configuration for this endpoint.
- multicast
- class TCPDeployment¶
Bases:
Layer4EndpointBase class for deploying a SOME/IP service onto a TCP-endpoint
SOME/IP Datatypes¶
Note
SOME/IP Datatypes are used to describe the parameters of messages that are transported in the payload.
defines the base class each datatype shares
- class PrimitiveDatatype(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
DatatypeBase class for primitive datatypes such as integers, floating-point values, or booleans.
Parameters¶
- namestr
Unique name of the datatype.
- descriptionstr, optional
Human-readable description of the datatype.
- typestr
Discriminator identifying the concrete primitive datatype kind.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Size in bits of the primitive datatype.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class ComplexDatatype(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
DatatypeBase class for complex datatypes such as structures, arrays, or unions.
Parameters¶
- namestr
Unique name of the datatype.
- descriptionstr, optional
Human-readable description of the datatype.
- typestr
Discriminator identifying the concrete complex datatype kind.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Boolean(*, name: str = 'BOOLEAN', description: str | None = '', type: Literal['boolean'] = 'boolean', endianness: Literal['BE'] = 'BE', member_name: str | None = None, signed: Literal[False] = False, bit_size: Annotated[int, Ge(ge=8), Le(le=8)] = 8)¶
Bases:
PrimitiveDatatypeBoolean primitive datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"BOOLEAN".- typeLiteral[“boolean”]
Discriminator identifying the primitive boolean datatype.
- signedLiteral[False]
Indicates that the boolean is unsigned.
- endiannessLiteral[“BE”]
Byte order used for encoding. Big-Endian (“BE”).
- bit_sizeint
Storage size in bits: 8.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class BaseInt(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
PrimitiveDatatypeBase class for all integer primitive datatypes.
This class provides shared semantics for signed and unsigned integer representations and defines common descriptive metadata.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class BaseFloat(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
PrimitiveDatatypeBase class for all floating-point primitive datatypes.
This class provides shared semantics for floating-point representations and defines common descriptive metadata.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class UInt8(*, name: str = 'UINT8', description: str | None = '', type: Literal['uint8'] = 'uint8', endianness: Literal['BE'] = 'BE', member_name: str | None = None, signed: Literal[False] = False, bit_size: int = 8)¶
Bases:
BaseIntUnsigned 8-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"UINT8".- typeLiteral[“uint8”]
Discriminator identifying this datatype.
- signedLiteral[False]
Indicates that the integer is unsigned.
- endiannessLiteral[“BE”]
Byte order used for encoding. Big-Endian (“BE”).
- bit_sizeint
Storage size in bits: 8.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class UInt16(*, name: str = 'UINT16', description: str | None = '', type: Literal['uint16'] = 'uint16', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[False] = False, bit_size: Annotated[int, Ge(ge=16), Le(le=16)] = 16)¶
Bases:
BaseIntUnsigned 16-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"UINT16".- typeLiteral[“uint16”]
Discriminator identifying this datatype.
- signedLiteral[False]
Indicates that the integer is unsigned.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 16.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class UInt32(*, name: str = 'UINT32', description: str | None = '', type: Literal['uint32'] = 'uint32', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[False] = False, bit_size: Annotated[int, Ge(ge=32), Le(le=32)] = 32)¶
Bases:
BaseIntUnsigned 32-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"UINT32".- typeLiteral[“uint32”]
Discriminator identifying this datatype.
- signedLiteral[False]
Indicates that the integer is unsigned.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 32.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class UInt64(*, name: str = 'UINT64', description: str | None = '', type: Literal['uint64'] = 'uint64', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[False] = False, bit_size: Annotated[int, Ge(ge=64), Le(le=64)] = 64)¶
Bases:
BaseIntUnsigned 64-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"UINT64".- typeLiteral[“uint64”]
Discriminator identifying this datatype.
- signedLiteral[False]
Indicates that the integer is unsigned.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 64.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Int8(*, name: str = 'INT8', description: str | None = '', type: Literal['int8'] = 'int8', endianness: Literal['BE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=8), Le(le=8)] = 8)¶
Bases:
BaseIntSigned 8-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"INT8".- typeLiteral[“int8”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the integer is signed.
- endiannessLiteral[“BE”]
Byte order used for encoding. Big-Endian (“BE”).
- bit_sizeint
Storage size in bits: 8.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Int16(*, name: str = 'INT16', description: str | None = '', type: Literal['int16'] = 'int16', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=16), Le(le=16)] = 16)¶
Bases:
BaseIntSigned 16-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"INT16".- typeLiteral[“int16”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the integer is signed.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 16.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Int32(*, name: str = 'INT32', description: str | None = '', type: Literal['int32'] = 'int32', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=32), Le(le=32)] = 32)¶
Bases:
BaseIntSigned 32-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"INT32".- typeLiteral[“int32”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the integer is signed.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 32.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Int64(*, name: str = 'INT64', description: str | None = '', type: Literal['int64'] = 'int64', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=64), Le(le=64)] = 64)¶
Bases:
BaseIntSigned 64-bit integer datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"INT64".- typeLiteral[“int64”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the integer is signed.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 64.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Float32(*, name: str = 'FLOAT32', description: str | None = '', type: Literal['float32'] = 'float32', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=32), Le(le=32)] = 32)¶
Bases:
PrimitiveDatatype32-bit floating-point datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"FLOAT32".- typeLiteral[“float32”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the float is signed.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 32.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Float64(*, name: str = 'FLOAT64', description: str | None = '', type: Literal['float64'] = 'float64', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, signed: Literal[True] = True, bit_size: Annotated[int, Ge(ge=64), Le(le=64)] = 64)¶
Bases:
BaseFloat64-bit floating-point datatype.
Parameters¶
- namestr
Datatype name. Defaults to
"FLOAT64".- typeLiteral[“float64”]
Discriminator identifying this datatype.
- signedLiteral[True]
Indicates that the float is signed.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- bit_sizeint
Storage size in bits: 64.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class BitfieldEntryValue(*, value: int, name: str, description: str | None = '')¶
Bases:
BaseModelRepresents a named value within a bitfield entry.
Parameters¶
- valueint
Numeric value represented by this bitfield entry value.
- namestr
Symbolic name associated with the value.
- descriptionstr, optional
Human-readable description of the value.
- model_config = {}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class BitfieldEntry(*, name: str, bitposition: int, description: str | None = '', values: List[BitfieldEntryValue] | None = <factory>)¶
Bases:
BaseModelDescribes a single field within a bitfield.
Parameters¶
- namestr
Name of the individual bitfield.
- bitpositionint
Bit position of the individual bitfield within the enclosing bitfield datatype.
- descriptionstr, optional
Human-readable description of the field.
- valueslist of
BitfieldEntryValue, optional Optional enumeration of named values defined for this bitfield entry.
- model_config = {}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class Bitfield(*, name: str = 'Bitfield', description: str | None = '', type: Literal['bitfield'] = 'bitfield', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, length: Literal[8, 16, 32, 64] = 8, fields: List[BitfieldEntry] | None = None)¶
Bases:
DatatypeAllows modeling of SOME/IP bitfields.
Parameters¶
- namestr
Unique name of the datatype.
- descriptionstr, optional
Human-readable description of the datatype.
- typeLiteral[“bitfield”]
Discriminator identifying this datatype as a bitfield.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- lengthLiteral[8, 16, 32, 64], optional
Size of the bitfield in bits.
- fieldslist of
BitfieldEntry List of bitfield entries that define the individual bit ranges.
- validate_length_against_fields_size()¶
Validate size of fields equals bitfield length
- validate_bitfieldposition_of_entries()¶
Validate bitfield position for all entries must be in range
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class EnumEntry(*, value: int, name: str, description: str = '')¶
Bases:
BaseModelRepresents a single entry in an enumeration.
Parameters¶
- valueint
Numeric value associated with the enumeration entry.
- namestr
Symbolic name of the enumeration entry.
- descriptionstr, optional
Human-readable description of the enumeration entry.
- model_config = {}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class Enum(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
DatatypeAllows modeling SOME/IP enumerations with value, name, and description.
Parameters¶
- namestr
Unique name of the datatype.
- descriptionstr, optional
Human-readable description of the datatype.
- typeLiteral[“enum”]
Datatype discriminator identifying this datatype as an enumeration.
- endiannessLiteral[“BE”, “LE”], optional
Byte order used for encoding multibyte values. Defaults to big-endian (“BE”).
- base_typeInts, optional
Underlying integer datatype used to encode enumeration values. Defaults to
UInt8.- entrieslist of
EnumEntry, optional List of enumeration entries defining the mapping between numeric values and symbolic names.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class BaseString(*, name: str = 'BaseString', description: str | None = '', type: str, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, encoding: Literal['UTF-8', 'UTF-16BE', 'UTF-16LE'] = 'UTF-8')¶
Bases:
DatatypeBase class for all string datatypes.
Parameters¶
- typestr
Discriminator identifying the concrete string type.
- encodingLiteral[“UTF-8”, “UTF-16BE”, “UTF-16LE”]
Character encoding used for the string payload.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class FixedLengthString(*, name: str = 'FixedLengthString', description: str | None = '', type: Literal['fixed_length_string'] = 'fixed_length_string', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, encoding: Literal['UTF-8', 'UTF-16BE', 'UTF-16LE'] = 'UTF-8', length: Annotated[int, Ge(ge=1)], length_of_length_field: Literal[0, 8, 16, 32] = 0)¶
Bases:
BaseStringFixed-length string datatype.
This string occupies a fixed number of bytes on the wire. If the actual content is shorter than the configured length, it is padded with zero bytes.
Parameters¶
- namestr
Name of the String.
- typeLiteral[“fixed_length_string”]
Discriminator used to identify this datatype.
- lengthint
Total length of the string in bytes, including zero-termination and any padding.
- length_of_length_fieldLiteral[0, 8, 16, 32]
Size of the optional length field in bits. A value of 0 indicates that no length field is present.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class DynamicLengthString(*, name: str = 'DynamicLengthString', description: str | None = '', type: Literal['dynamic_length_string'] = 'dynamic_length_string', endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None, encoding: Literal['UTF-8', 'UTF-16BE', 'UTF-16LE'] = 'UTF-8', max_length: Annotated[int | None, Ge(ge=0)] = None, min_length: Annotated[int | None, Ge(ge=0)] = None, length_of_length_field: Literal[8, 16, 32] = 32, bit_alignment: Literal[8, 16, 32, 64, 128, 256] = 8)¶
Bases:
BaseStringDynamic-length string datatype.
The encoded representation starts with a length field, followed by the string content and a zero-termination character.
Parameters¶
- namestr
Name of the String.
- typeLiteral[“dynamic_length_string”]
Discriminator used to identify this datatype.
- max_length: Optional[int]
Maximum string length in bytes. None means no limit.
- min_length: Optional[int]
Minimum string length in bytes. None means 0.
- length_of_length_fieldLiteral[8, 16, 32]
Size of the length field in bits that precedes the string data.
- bit_alignmentLiteral[8, 16, 32, 64, 128, 256]
Optional padding alignment applied after the string so that the next parameter starts at the specified bit boundary.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class ArrayType(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
ComplexDatatypeGeneric multidimensional array type.
Parameters¶
- namestr
Name of Array.
- typeLiteral[“array”]
Discriminator identifying this datatype as an array.
- dimensionsList[
ArrayDimension] Ordered list of array dimensions (outer → inner). Must contain at least one dimension.
- element_type
AllTypes Datatype of the innermost array element. This may itself be a primitive, struct, union, or another array type.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class ArrayDimension(*, kind: Literal['fixed', 'dynamic'], length: Annotated[int | None, Gt(gt=0)] = None, length_of_length_field: Literal[0, 8, 16, 32] | None = None, upper_limit: Annotated[int | None, Gt(gt=0)] = None, lower_limit: Annotated[int | None, Ge(ge=0)] = None, bit_alignment: Literal[8, 16, 32, 64, 128, 256] | None = None)¶
Bases:
FLYNCBaseModelDescribes a single array dimension.
Parameters¶
- kindLiteral[“fixed”, “dynamic”]
Specifies whether the dimension has a fixed size or a dynamically encoded length.
- lengthint, optional
Number of elements for a fixed-length dimension. Must be greater than 0. Only valid when
kind="fixed".- length_of_length_fieldLiteral[0, 8, 16, 32], optional
Size in bits of the length field that precedes the array data for a dynamic dimension. Only valid when
kind="dynamic".- upper_limitint, optional
Upper bound on the number of elements. Must be greater than 0.
- lower_limitint, optional
Lower bound on the number of elements. Must be greater than or equal to 0.
- bit_alignmentLiteral[8, 16, 32, 64, 128, 256], optional
Optional padding alignment in bits applied after this dimension.
- model_config = {'extra': 'forbid'}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Struct(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
ComplexDatatypeStructured datatype composed of multiple ordered members.
A struct groups several datatypes into a single composite element that is serialized in the order the members are defined.
Parameters¶
- typeLiteral[“struct”]
Discriminator used to identify this datatype.
- membersList[AllTypes]
Ordered list of datatypes that form the members of the struct.
- bit_alignmentLiteral[8, 16, 32, 64, 128, 256]
Optional padding alignment applied after the struct to ensure the next parameter starts at the specified bit boundary.
- length_of_length_fieldLiteral[0, 8, 16, 32]
Size of the optional length field in bits that prefixes the struct. A value of 0 indicates that no length field is present.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Typedef(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
ComplexDatatypeAlias datatype that references another datatype definition.
A typedef introduces an alternative name for an existing datatype without changing its underlying structure or serialization behavior.
Parameters¶
- typeLiteral[“typedef”]
Discriminator used to identify this datatype.
- namestr
Name of the typedef reference.
- datatyperefAllTypes
Referenced datatype definition that this typedef aliases.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class UnionMember(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
DatatypeRepresents a single member entry of a union datatype.
Each union member defines a possible datatype that may be present, together with its selector index and a descriptive name.
Parameters¶
- typeAllTypes
Member datatype (discriminated by its
typefield).- indexint
Index of the union member. This value is used in the serialized union to indicate which member is currently active. Must be greater than or equal to 0.
- namestr
Name of the union member.
- mandatorybool
Whether the union member is mandatory.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- class Union(*, name: str, description: str | None = '', type: str | object, endianness: Literal['BE', 'LE'] = 'BE', member_name: str | None = None)¶
Bases:
DatatypeRepresents a union datatype.
A union allows exactly one of several possible member datatypes to be encoded at runtime. The active member is identified using a type selector field.
Parameters¶
- namestr
Name of the Union.
- typeLiteral[“union”]
Discriminator used to identify this datatype.
- memberslist of
UnionMember List of the allowed datatypes a union can contain.
- bit_alignmentLiteral[8, 16, 32, 64, 128, 256], optional
Defines the optional alignment padding that can be added after the union to fix the alignment of the next parameter to 8, 16, 32, 64, 128 or 256 bits.
- length_of_length_fieldLiteral[0, 8, 16, 32], optional
Defines the length of the length-field in bits for the union.
- length_of_type_fieldLiteral[0, 8, 16, 32], optional
Defines the length of the type-selector field in bits for the union.
- model_config = {'extra': 'forbid', 'frozen': True}¶
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_post_init(_FLYNCBaseModel__context)¶
Override this method to perform additional initialization after __init__ and model_construct. This is useful if you want to do some validation that requires the entire model to be initialized.
- SignedInts¶
Collection of Signed Integer Types
alias of
Annotated[Int8|Int16|Int32|Int64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)]
- UnsignedInts¶
Collection of Unsigned Integer Types
alias of
Annotated[UInt8|UInt16|UInt32|UInt64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)]
- Ints¶
Collection of Integer Types
alias of
Annotated[Annotated[Int8|Int16|Int32|Int64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)] |Annotated[UInt8|UInt16|UInt32|UInt64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)], FieldInfo(annotation=NoneType, required=True, discriminator=’type’)]
- Floats¶
Collection of Float Types
alias of
Annotated[Float32|Float64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)]
- AllTypes¶
Collection of all dataypes
alias of
Annotated[Annotated[Annotated[Int8|Int16|Int32|Int64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)] |Annotated[UInt8|UInt16|UInt32|UInt64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)], FieldInfo(annotation=NoneType, required=True, discriminator=’type’)] |Annotated[Float32|Float64, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)] |Enum|Boolean|Struct|Typedef|Union|ArrayType|DynamicLengthString|FixedLengthString|Bitfield, FieldInfo(annotation=NoneType, required=True, discriminator=’type’)]