Class: FieldConfiguration
options.JSONSchema.FieldConfiguration
'FieldConfiguration' provides additional field level properties used when generating the OpenAPI v2 file. These properties are not defined by OpenAPIv2, but they are used to control the generation.
Properties
pathParamName
• pathParamName: string
Alternative parameter name when used as path parameter. If set, this will be used as the complete parameter name when this field is used as a path parameter. Use this to avoid having auto generated path parameter names for overlapping paths.
Methods
toJSON
▸ toJSON(): Object
Converts this FieldConfiguration to JSON.
Returns
Object
JSON object
create
▸ create(properties?): FieldConfiguration & $Properties
Creates a new FieldConfiguration instance using the specified properties.
Parameters
| Name | Type | Description |
|---|---|---|
properties? | $Properties | Properties to set |
Returns
FieldConfiguration & $Properties
FieldConfiguration instance
▸ create(properties?): FieldConfiguration
Parameters
| Name | Type |
|---|---|
properties? | $Properties |
Returns
decode
▸ decode(reader, length?): FieldConfiguration & $Properties
Decodes a FieldConfiguration message from the specified reader or buffer.
Parameters
| Name | Type | Description |
|---|---|---|
reader | Uint8Array | Reader | Reader or buffer to decode from |
length? | number | Message length if known beforehand |
Returns
FieldConfiguration & $Properties
FieldConfiguration
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
decodeDelimited
▸ decodeDelimited(reader): FieldConfiguration & $Properties
Decodes a FieldConfiguration message from the specified reader or buffer, length delimited.
Parameters
| Name | Type | Description |
|---|---|---|
reader | Uint8Array | Reader | Reader or buffer to decode from |
Returns
FieldConfiguration & $Properties
FieldConfiguration
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
encode
▸ encode(message, writer?): Writer
Encodes the specified FieldConfiguration message. Does not implicitly grpc.gateway.protoc_gen_openapiv2.options.JSONSchema.FieldConfiguration.verify|verify messages.
Parameters
| Name | Type | Description |
|---|---|---|
message | $Properties | FieldConfiguration message or plain object to encode |
writer? | Writer | Writer to encode to |
Returns
Writer
Writer
encodeDelimited
▸ encodeDelimited(message, writer?): Writer
Encodes the specified FieldConfiguration message, length delimited. Does not implicitly grpc.gateway.protoc_gen_openapiv2.options.JSONSchema.FieldConfiguration.verify|verify messages.
Parameters
| Name | Type | Description |
|---|---|---|
message | $Properties | FieldConfiguration message or plain object to encode |
writer? | Writer | Writer to encode to |
Returns
Writer
Writer
fromObject
▸ fromObject(object): FieldConfiguration
Creates a FieldConfiguration message from a plain object. Also converts values to their respective internal types.
Parameters
| Name | Type | Description |
|---|---|---|
object | Object | Plain object |
Returns
FieldConfiguration
toObject
▸ toObject(message, options?): Object
Creates a plain object from a FieldConfiguration message. Also converts values to other types if specified.
Parameters
| Name | Type | Description |
|---|---|---|
message | FieldConfiguration | FieldConfiguration |
options? | IConversionOptions | Conversion options |
Returns
Object
Plain object