Class Openapiv2.Schema.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
grpc.gateway.protoc_gen_openapiv2.options.Openapiv2.Schema.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Openapiv2.SchemaOrBuilder
,Cloneable
- Enclosing class:
- Openapiv2.Schema
public static final class Openapiv2.Schema.Builder
extends com.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
implements Openapiv2.SchemaOrBuilder
`Schema` is a representation of OpenAPI v2 specification's Schema object. See: https://github.com/OAI/OpenAPI-Specification/blob/3.0.0/versions/2.0.md#schemaObjectProtobuf type
grpc.gateway.protoc_gen_openapiv2.options.Schema
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
clear()
Adds support for polymorphism.A free-form property to include an example of an instance for this schema in JSON.Additional external documentation for this schema..grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
Relevant only for Schema "properties" definitions.static final com.google.protobuf.Descriptors.Descriptor
com.google.protobuf.Descriptors.Descriptor
Adds support for polymorphism.com.google.protobuf.ByteString
Adds support for polymorphism.A free-form property to include an example of an instance for this schema in JSON.com.google.protobuf.ByteString
A free-form property to include an example of an instance for this schema in JSON.Additional external documentation for this schema.Additional external documentation for this schema.Additional external documentation for this schema..grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
boolean
Relevant only for Schema "properties" definitions.boolean
Additional external documentation for this schema.boolean
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
final boolean
Additional external documentation for this schema.mergeFrom
(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom
(com.google.protobuf.Message other) mergeFrom
(Openapiv2.Schema other) .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
setDiscriminator
(String value) Adds support for polymorphism.setDiscriminatorBytes
(com.google.protobuf.ByteString value) Adds support for polymorphism.setExample
(String value) A free-form property to include an example of an instance for this schema in JSON.setExampleBytes
(com.google.protobuf.ByteString value) A free-form property to include an example of an instance for this schema in JSON.Additional external documentation for this schema.setExternalDocs
(Openapiv2.ExternalDocumentation.Builder builderForValue) Additional external documentation for this schema..grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
setJsonSchema
(Openapiv2.JSONSchema.Builder builderForValue) .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
setReadOnly
(boolean value) Relevant only for Schema "properties" definitions.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFrom
Methods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFrom
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
-
clear
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Openapiv2.Schema.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage.Builder<Openapiv2.Schema.Builder>
-
mergeFrom
public Openapiv2.Schema.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Openapiv2.Schema.Builder>
- Throws:
IOException
-
hasJsonSchema
public boolean hasJsonSchema().grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
- Specified by:
hasJsonSchema
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- Whether the jsonSchema field is set.
-
getJsonSchema
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
- Specified by:
getJsonSchema
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The jsonSchema.
-
setJsonSchema
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
-
setJsonSchema
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
-
mergeJsonSchema
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
-
clearJsonSchema
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
-
getJsonSchemaBuilder
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
-
getJsonSchemaOrBuilder
.grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
- Specified by:
getJsonSchemaOrBuilder
in interfaceOpenapiv2.SchemaOrBuilder
-
getDiscriminator
Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between other schema that inherit this schema. The property name used MUST be defined at this schema and it MUST be in the required property list. When used, the value MUST be the name of this schema or any schema that inherits it.
string discriminator = 2;
- Specified by:
getDiscriminator
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The discriminator.
-
getDiscriminatorBytes
public com.google.protobuf.ByteString getDiscriminatorBytes()Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between other schema that inherit this schema. The property name used MUST be defined at this schema and it MUST be in the required property list. When used, the value MUST be the name of this schema or any schema that inherits it.
string discriminator = 2;
- Specified by:
getDiscriminatorBytes
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The bytes for discriminator.
-
setDiscriminator
Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between other schema that inherit this schema. The property name used MUST be defined at this schema and it MUST be in the required property list. When used, the value MUST be the name of this schema or any schema that inherits it.
string discriminator = 2;
- Parameters:
value
- The discriminator to set.- Returns:
- This builder for chaining.
-
clearDiscriminator
Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between other schema that inherit this schema. The property name used MUST be defined at this schema and it MUST be in the required property list. When used, the value MUST be the name of this schema or any schema that inherits it.
string discriminator = 2;
- Returns:
- This builder for chaining.
-
setDiscriminatorBytes
Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between other schema that inherit this schema. The property name used MUST be defined at this schema and it MUST be in the required property list. When used, the value MUST be the name of this schema or any schema that inherits it.
string discriminator = 2;
- Parameters:
value
- The bytes for discriminator to set.- Returns:
- This builder for chaining.
-
getReadOnly
public boolean getReadOnly()Relevant only for Schema "properties" definitions. Declares the property as "read only". This means that it MAY be sent as part of a response but MUST NOT be sent as part of the request. Properties marked as readOnly being true SHOULD NOT be in the required list of the defined schema. Default value is false.
bool read_only = 3;
- Specified by:
getReadOnly
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The readOnly.
-
setReadOnly
Relevant only for Schema "properties" definitions. Declares the property as "read only". This means that it MAY be sent as part of a response but MUST NOT be sent as part of the request. Properties marked as readOnly being true SHOULD NOT be in the required list of the defined schema. Default value is false.
bool read_only = 3;
- Parameters:
value
- The readOnly to set.- Returns:
- This builder for chaining.
-
clearReadOnly
Relevant only for Schema "properties" definitions. Declares the property as "read only". This means that it MAY be sent as part of a response but MUST NOT be sent as part of the request. Properties marked as readOnly being true SHOULD NOT be in the required list of the defined schema. Default value is false.
bool read_only = 3;
- Returns:
- This builder for chaining.
-
hasExternalDocs
public boolean hasExternalDocs()Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
- Specified by:
hasExternalDocs
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- Whether the externalDocs field is set.
-
getExternalDocs
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
- Specified by:
getExternalDocs
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The externalDocs.
-
setExternalDocs
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
-
setExternalDocs
public Openapiv2.Schema.Builder setExternalDocs(Openapiv2.ExternalDocumentation.Builder builderForValue) Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
-
mergeExternalDocs
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
-
clearExternalDocs
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
-
getExternalDocsBuilder
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
-
getExternalDocsOrBuilder
Additional external documentation for this schema.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
- Specified by:
getExternalDocsOrBuilder
in interfaceOpenapiv2.SchemaOrBuilder
-
getExample
A free-form property to include an example of an instance for this schema in JSON. This is copied verbatim to the output.
string example = 6;
- Specified by:
getExample
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The example.
-
getExampleBytes
public com.google.protobuf.ByteString getExampleBytes()A free-form property to include an example of an instance for this schema in JSON. This is copied verbatim to the output.
string example = 6;
- Specified by:
getExampleBytes
in interfaceOpenapiv2.SchemaOrBuilder
- Returns:
- The bytes for example.
-
setExample
A free-form property to include an example of an instance for this schema in JSON. This is copied verbatim to the output.
string example = 6;
- Parameters:
value
- The example to set.- Returns:
- This builder for chaining.
-
clearExample
A free-form property to include an example of an instance for this schema in JSON. This is copied verbatim to the output.
string example = 6;
- Returns:
- This builder for chaining.
-
setExampleBytes
A free-form property to include an example of an instance for this schema in JSON. This is copied verbatim to the output.
string example = 6;
- Parameters:
value
- The bytes for example to set.- Returns:
- This builder for chaining.
-