better formnat

This commit is contained in:
William Cheng 2025-01-14 14:26:24 +08:00
parent 19f307d6cd
commit 01584fed76

View File

@ -426,18 +426,18 @@ public class ModelUtils {
* A ObjectSchema differs from a MapSchema in the following way: * A ObjectSchema differs from a MapSchema in the following way:
* - An ObjectSchema is not extensible, i.e. it has a fixed number of properties. * - An ObjectSchema is not extensible, i.e. it has a fixed number of properties.
* - A MapSchema is an object that can be extended with an arbitrary set of properties. * - A MapSchema is an object that can be extended with an arbitrary set of properties.
* The payload may include dynamic properties. * The payload may include dynamic properties.
* <p> * <p>
* For example, an OpenAPI schema is considered an ObjectSchema in the following scenarios: * For example, an OpenAPI schema is considered an ObjectSchema in the following scenarios:
* <p> * <p>
* <p> * <p>
* type: object * type: object
* additionalProperties: false * additionalProperties: false
* properties: * properties:
* name: * name:
* type: string * type: string
* address: * address:
* type: string * type: string
* *
* @param schema the OAS schema * @param schema the OAS schema
* @return true if the specified schema is an Object schema. * @return true if the specified schema is an Object schema.
@ -527,7 +527,7 @@ public class ModelUtils {
* A MapSchema differs from an ObjectSchema in the following way: * A MapSchema differs from an ObjectSchema in the following way:
* - An ObjectSchema is not extensible, i.e. it has a fixed number of properties. * - An ObjectSchema is not extensible, i.e. it has a fixed number of properties.
* - A MapSchema is an object that can be extended with an arbitrary set of properties. * - A MapSchema is an object that can be extended with an arbitrary set of properties.
* The payload may include dynamic properties. * The payload may include dynamic properties.
* <p> * <p>
* Note that isMapSchema returns true for a composed schema (allOf, anyOf, oneOf) that also defines * Note that isMapSchema returns true for a composed schema (allOf, anyOf, oneOf) that also defines
* additionalproperties. * additionalproperties.
@ -840,21 +840,21 @@ public class ModelUtils {
* Examples: * Examples:
* <p> * <p>
* components: * components:
* schemas: * schemas:
* arbitraryObject: * arbitraryObject:
* type: object * type: object
* description: This is a free-form object. * description: This is a free-form object.
* The value must be a map of strings to values. The value cannot be 'null'. * The value must be a map of strings to values. The value cannot be 'null'.
* It cannot be array, string, integer, number. * It cannot be array, string, integer, number.
* arbitraryNullableObject: * arbitraryNullableObject:
* type: object * type: object
* description: This is a free-form object. * description: This is a free-form object.
* The value must be a map of strings to values. The value can be 'null', * The value must be a map of strings to values. The value can be 'null',
* It cannot be array, string, integer, number. * It cannot be array, string, integer, number.
* nullable: true * nullable: true
* arbitraryTypeValue: * arbitraryTypeValue:
* description: This is NOT a free-form object. * description: This is NOT a free-form object.
* The value can be any type except the 'null' value. * The value can be any type except the 'null' value.
* *
* @param schema potentially containing a '$ref' * @param schema potentially containing a '$ref'
* @param openAPI document containing the Schema. * @param openAPI document containing the Schema.