Skip to content

When processing primitive types look for the 'format' field and if can add getters/setters that enforce this/use appropriate php types #2

@SDParish

Description

@SDParish

See https://swagger.io/specification/v2/#data-types for information on the format field.
Note that format is both optional, and can be any string, so if not found or recognised, will need to gracefully ignore.

Specifically, where format is date/date-time the model could enforce that set strings are in the required format, and could also allow setting from a DateTimeInterface, or allow getting as a DateTimeImmutable or DateTime.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions