33Global type mapping will replace **any** usage of an OpenAPI type in the api description to the
44given java type.
55
6- It is defined like below and it should be added to the `map/types` section in the `mapping.yaml`
6+ It is defined like below, and it should be added to the `map/types` section in the `mapping.yaml`
77which is a list of global type mappings.
88
99A single global mapping can have the following properties:
@@ -50,7 +50,7 @@ can be mapped to an existing `Book` java type/class by the following mapping:
5050 to: com.github.hauner.openapi.oap.Book
5151----
5252
53- It is also possible to use a predefined OpenAPI type as the `from` type of a type mapping:
53+ It is also possible to use a predefined OpenAPI type in the `from` type of the type mapping:
5454
5555[source,yaml]
5656----
@@ -60,7 +60,7 @@ It is also possible to use a predefined OpenAPI type as the `from` type of a typ
6060
6161This tells the processor to us a `java.util.List` instead of the OpenAPI type `array`.
6262
63- The **generics** parameter is not required in this special case. The processor knows `java.util.List`
63+ The **generics** parameter is unnecessary in this special case. The processor knows `java.util.List`
6464and will automatically use the `items` property of the `array` as the generic type.
6565
6666[CAUTION]
@@ -69,7 +69,7 @@ and will automatically use the `items` property of the `array` as the generic ty
6969assumes that it is just a schema name and it will only match if there is a schema with the name
7070"object".
7171* global type mappings do work on OpenAPI inline schemas using the automatically generated name.
72- This is not recommended as a small change to the api description could changes the inline name and
72+ This is not recommended as a small change to the api description could change the inline name and
7373break the mapping.
7474====
7575
@@ -89,16 +89,16 @@ to the **from** property value separated by a ':' like this:
8989 to: java.time.ZonedDateTime
9090----
9191
92- This maps the `string` type with `date-time` format from the default `java.time.OffsetDateTime` to
93- `java.time.ZonedDateTime`. `string` without format or `string` with other formats are not affected
94- by this mapping .
92+ This maps the `string` type with a `date-time` format from the default `java.time.OffsetDateTime` to
93+ `java.time.ZonedDateTime`. The mapping does not affect `string` without a format or `string` with
94+ other formats .
9595
9696== mapping with generic types
9797
98- Type mapping allows to use a target type that has generic parameters. The generic types are defined
98+ Type mapping allows to use a target type that has generic parameters. The generic types are given
9999by the **generics** property of the mapping. **generics** is a list and can contain multiple types.
100100
101- For example if a `StringPage` schema is defined in the OpenAPI that corresponds to
101+ For example if a `StringPage` schema in the OpenAPI corresponds to
102102`org.springframework.data.domain.Page<java.lang.String>`, it can be mapped to the Spring type by:
103103
104104[source,yaml]
0 commit comments