@@ -430,8 +430,8 @@ type Discriminator struct {
430430 Extensions map[string]any `json:"-" yaml:"-"`
431431 Origin *Origin `json:"__origin__,omitempty" yaml:"__origin__,omitempty"`
432432
433- PropertyName string `json:"propertyName" yaml:"propertyName"` // required
434- Mapping StringMap `json:"mapping,omitempty" yaml:"mapping,omitempty"`
433+ PropertyName string `json:"propertyName" yaml:"propertyName"` // required
434+ Mapping StringMap[MappingRef] `json:"mapping,omitempty" yaml:"mapping,omitempty"`
435435}
436436 Discriminator is specified by OpenAPI/Swagger standard version 3. See
437437 https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#discriminator-object
@@ -847,6 +847,15 @@ type Location struct {
847847}
848848 Location is a struct that contains the location of a field.
849849
850+ type MappingRef SchemaRef
851+ MappingRef is a ref to a Schema objects. Unlike SchemaRefs it is serialised
852+ as a plain string instead of an object with a $ref key, as such it also does
853+ not support extensions.
854+
855+ func (mr MappingRef) MarshalText() ([]byte, error)
856+
857+ func (mr *MappingRef) UnmarshalText(data []byte) error
858+
850859type MediaType struct {
851860 Extensions map[string]any `json:"-" yaml:"-"`
852861 Origin *Origin `json:"__origin__,omitempty" yaml:"__origin__,omitempty"`
@@ -929,10 +938,10 @@ type OAuthFlow struct {
929938 Extensions map[string]any `json:"-" yaml:"-"`
930939 Origin *Origin `json:"__origin__,omitempty" yaml:"__origin__,omitempty"`
931940
932- AuthorizationURL string `json:"authorizationUrl,omitempty" yaml:"authorizationUrl,omitempty"`
933- TokenURL string `json:"tokenUrl,omitempty" yaml:"tokenUrl,omitempty"`
934- RefreshURL string `json:"refreshUrl,omitempty" yaml:"refreshUrl,omitempty"`
935- Scopes StringMap `json:"scopes" yaml:"scopes"` // required
941+ AuthorizationURL string `json:"authorizationUrl,omitempty" yaml:"authorizationUrl,omitempty"`
942+ TokenURL string `json:"tokenUrl,omitempty" yaml:"tokenUrl,omitempty"`
943+ RefreshURL string `json:"refreshUrl,omitempty" yaml:"refreshUrl,omitempty"`
944+ Scopes StringMap[string] `json:"scopes" yaml:"scopes"` // required
936945}
937946 OAuthFlow is specified by OpenAPI/Swagger standard version 3. See
938947 https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#oauth-flow-object
@@ -2083,11 +2092,11 @@ func NewRegexpFormatValidator(pattern string) StringFormatValidator
20832092 NewRegexpFormatValidator creates a new FormatValidator that uses a regular
20842093 expression to validate the value.
20852094
2086- type StringMap map[string]string
2095+ type StringMap[V any] map[string]V
20872096 StringMap is a map[string]string that ignores the origin in the underlying
20882097 json representation.
20892098
2090- func (stringMap *StringMap) UnmarshalJSON(data []byte) (err error)
2099+ func (stringMap *StringMap[V] ) UnmarshalJSON(data []byte) (err error)
20912100 UnmarshalJSON sets StringMap to a copy of data.
20922101
20932102type T struct {
0 commit comments