Skip to content

Files

Latest commit

5e9f988 · Sep 30, 2021

History

History
25 lines (16 loc) · 787 Bytes

README.md

File metadata and controls

25 lines (16 loc) · 787 Bytes

openapi-generator-cli-usage

The batch file for generating code from JSON schema files.
Includes options for adding validation annotations to generated GTO's.

See:
OpenAPITools https://github.com/OpenAPITools/openapi-generator-cli
Config Options for Spring https://openapi-generator.tech/docs/generators/spring/

To suppress serializing properties with null values (using Jackson >2.0), you can anntotate generated DTO class with @JsonInclude.

Example:
@JsonInclude(value=JsonInclude.Include.NON_NULL)
public class YouGenareatedDto { }

Annotation that can be used to ignore processing of JSON properties read (during deserialization).

Example:
@JsonIgnoreProperties(ignoreUnknown = true)
public class YouGenareatedDto { }