Skip to content

add model factory? #20

Closed
Closed
@vincentsarago

Description

@vincentsarago

sometime a user (me) would want to specify the GeoJSON model up to the geometry type (e.g. my geojson is a polygon only)

we can use pydantic.create_model: https://pydantic-docs.helpmanual.io/usage/models/#dynamic-model-creation

example: https://github.com/arturo-ai/stac-pydantic/blob/master/stac_pydantic/item.py#L96-L110

Metadata

Metadata

Assignees

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