PropertySchema2.2.0
- Known subtypes:
- Known usages:
- All versions:
Properties(show inherited)
-
expand_morelinkhidden
The output of this module.
Defaults to all module properties rendered as either Pcf or the format specified on the command line.
-
expand_morelinkSchema.type: ("string"|"number"|"integer"|"boolean"|"object"|"array")? (org.openapis.v3.Schema)Source
The basic type of the value represented by this schema.
If this property is not defined, the value may be of any type.
-
expand_morelinkSchema.format: ("int32"|"int64"|"float"|"double"|"byte"|"binary"|"date"|"date-time"|"password"|String)? (org.openapis.v3.Schema)Source
An additional descriptor for the value represented by this schema.
OAS uses several known formats to define in fine detail the data type being used.
However, to support documentation needs, the
formatproperty is an openstring-valued property, and can have any value. Formats such as"email","uuid", and so on, may be used even though undefined by this specification. Types that are not accompanied by aformatproperty follow the type definition in the JSON Schema. Tools that do not recognize a specificformatmay default to thetypealone, as if theformatis not specified.The formats defined by the OAS are:
Common Name typeformatComments integer integerint32signed 32 bits long integerint64signed 64 bits float numberfloatdouble numberdoublestring stringbyte stringbytebase64 encoded characters binary stringbinaryany sequence of octets boolean booleandate stringdateAs defined by full-date- RFC3339dateTime stringdate-timeAs defined by date-time- RFC3339password stringpasswordA hint to UIs to obscure input. https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#dataTypeFormat
-
-
-
expand_morelink
Specifies a default value.
This value is not used to fill in missing values during the validation process. Non-validation tools such as documentation generators or form generators may use this value to give hints to users about how to use a value. However,
defaultis typically used to express that if a value is missing, then the value is semantically the same as if the value was present with the default value. The value ofdefaultshould validate against the schema in which it resides, but that isn't required.https://json-schema.org/understanding-json-schema/reference/generic.html#annotations
-
expand_morelink
Restricts the value specified by this schema to a fixed set of values.
It must be an array with at least one element, where each element is unique.
You can use enum even without a type, to accept values of different types.
Elements in the array might be of any type, including
null. https://json-schema.org/understanding-json-schema/reference/generic.html#enumerated-values -
expand_morelinkSchema.multipleOf: Number(type is ("number"|"integer") && isPositive)? (org.openapis.v3.Schema)Source
Restricts to a number that is a multiple of this value.
It may be set to any positive number.
https://json-schema.org/understanding-json-schema/reference/numeric.html#multiples
-
-
-
-
-
expand_morelink
Represent a string that adheres to a regex pattern.
The regular expression must conform to ECMA 262.
https://json-schema.org/understanding-json-schema/reference/string.html#regular-expressions
-
-
-
-
-
-
-
-
-
expand_morelinkSchema.properties: Mapping<String, (PropertySchema|Reference)>(type == "object")? (org.openapis.v3.Schema)Source
Represent an object that have properties that conform to a certain schema.
-
expand_morelinkSchema.additionalProperties: (PropertySchema|Boolean|Reference)(type == "object")? (org.openapis.v3.Schema)Source
Represent an object that has additional properties.
The value of
additionalPropertiesis a schema that will be used to validate any properties in the instance that are not matched byproperties. Setting theadditionalPropertiesschema tofalsemeans no additional properties will be allowed.https://json-schema.org/understanding-json-schema/reference/object.html#additional-properties
-
expand_morelink
Represent an object that has certain properties defined on it.
By default, no properties are required.
https://json-schema.org/understanding-json-schema/reference/object.html#required-properties
-
-
-
-
-
expand_morelink
Represent that the value may optionally be
null.Default value is
false.https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#fixed-fields-20
-
expand_morelink
Helps inform of alternative schemas.
When request bodies or response payloads may be one of a number of different schemas, a discriminator object can be used to aid in serialization, deserialization, and validation. The discriminator is a specific object in a schema which is used to inform the consumer of the specification of an alternative schema based on the value associated with it.
When using the discriminator, inline schemas will not be considered.
https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#discriminator-object
-
expand_morelink
Declares the property as "read only".
Relevant only for Schema
propertiesdefinitions. This means that it may be sent as part of a response but should not be sent as part of the request. If the property is marked asreadOnlyand is in therequiredlist,requiredonly effects the response. A property may not be marked as bothreadOnlyandwriteOnly.Default value is
false.https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#fixed-fields-20
-
expand_morelink
Declares the property as "write only".
This is relevant only for Schema
propertiesdefinitions. Therefore, it it may be sent as part of a response but should not be sent as part If the property is marked aswriteOnlybeingtrueand is in therequiredlist, therequiredwill take effect on the request only. A property may not be marked as bothreadOnlyandwriteOnlybeingtrue.Default value is
false.https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#fixed-fields-20
-
-
expand_morelink
Indicates that this property is deprecated.
Default value is
false.https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#fixed-fields-20
-
expand_morelink
A free-form property to include an example of an instance for this schema.
To represent examples that cannot be naturally represented in JSON or YAML, a string value can be used to contain the example with escaping where necessary.
-
expand_morelinkhidden
Custom properties starting with x- extend OpenAPI with additional information or functionality.
This is a child property because Pkl modules cannot express both known names and arbitrary names.
https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#specification-extensions
-
Methods(show inherited)
-
-
-
-
-
-
-
-
-
expand_morelinkfunction
Returns the relative, descendent directory path between this module and
other.Throws if no such path exists.
For example, if module
mod1has path/dir1/mod1.pkl, and modulemod2has path/dir1/dir2/dir3/mod2.pkl, thenmod1.relativePathTo(mod2)will returnList("dir2", "dir3").A common use case is to compute the directory path between a template located at the root of a hierarchy (say
rootModule.pkl) and the currently evaluated module (accessible via themodulekeyword):import "rootModule.pkl" // self-import path = rootModule.relativePathTo(module)
Property schemas are
Schemas that optionally include XML metadata.