Skip to content

Size

Bases: Quantity

Represents a size definition for a part or feature in an engineering context.

PARAMETER DESCRIPTION
value

The value of the quantity.

TYPE: Decimal

unit

The unit of the quantity.

TYPE: str

size_type

The type of size (e.g., diameter, linear, angular).

TYPE: SizeType

tolerance

The tolerance specifications associated with the size.

TYPE: Tolerance | None DEFAULT: None

Source code in werk24/models/v2/models.py
class Size(Quantity):
    """
    Represents a size definition for a part or feature in an engineering context.
    """

    size_type: SizeType = Field(
        ...,
        description="The type of size (e.g., diameter, linear, angular).",
        examples=[SizeType.DIAMETER],
    )

    tolerance: Optional[Tolerance] = Field(
        None,
        description="The tolerance specifications associated with the size.",
        examples=[
            Tolerance(
                fit="H7",
                deviation_lower=Decimal("-0.05"),
                deviation_upper=Decimal("0.05"),
                tolerance_grade="IT7",
            )
        ],
    )