Replies: 1 comment
-
|
Thank you for your feedback! Currently, this tool is fundamentally designed with Python output in mind, so supporting non-Python languages like Java would be challenging with the existing architecture. The import system, formatters, and template structure are all Python-specific. That said, we have received similar requests before, such as generating Swift code. If there is enough demand for multi-language support, we would consider implementing features to accommodate other languages. If you have any thoughts, ideas, or use cases, please feel free to share them in the comments. Your feedback helps us prioritize future development. Thanks again! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I searched for a similar discussion without match. Please excuse me if it's a duplicate.
I'm trying to generate custom code, out of pydantic. I first attempted to generate java pojo.
I've gone through the doc. I managed to use
$ datamodel-codegen --input {your_input_file} --output {your_output_file} --custom-template-dir {your_custom_template_directory}.But it seems to lack some flexibility :
--output-model-type {pydantic.BaseModel,pydantic_v2.BaseModel,dataclasses.dataclass,typing.TypedDict,msgspec.Struct}.Is there a way to generate code out of python+pydantic ?
Cheers
Beta Was this translation helpful? Give feedback.
All reactions