-
|
First of all thanks @nazrulworld for this library. A newbie question: Can you advise if there is a difference using init() and parse_obj() for creating a resource (apart from the latter using a class method to create the object)? In the code below, p1 & p2 seem identical. Does one have different validation and/or performance than the other? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Hi @df65,
This page probably answers your question: https://docs.pydantic.dev/usage/models/#helper-functions
|
Beta Was this translation helpful? Give feedback.
Hi @df65,
fhir.resourcesis built on top ofpydanticand I think your question is mainly about howpydanticmodels work.This page probably answers your question: https://docs.pydantic.dev/usage/models/#helper-functions