MCPcopy
hub / github.com/pydantic/pydantic / schema

Method schema

pydantic/v1/main.py:683–689  ·  view source on GitHub ↗
(cls, by_alias: bool = True, ref_template: str = default_ref_template)

Source from the content-addressed store, hash-verified

681
682 @classmethod
683 def schema(cls, by_alias: bool = True, ref_template: str = default_ref_template) -> 'DictStrAny':
684 cached = cls.__schema_cache__.get((by_alias, ref_template))
685 if cached is not None:
686 return cached
687 s = model_schema(cls, by_alias=by_alias, ref_template=ref_template)
688 cls.__schema_cache__[(by_alias, ref_template)] = s
689 return s
690
691 @classmethod
692 def schema_json(

Callers 2

schema_ofFunction · 0.45
schema_jsonMethod · 0.45

Calls 2

model_schemaFunction · 0.90
getMethod · 0.45

Tested by

no test coverage detected