Class Openapiv2.Schema.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.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#schemaObject
 
Protobuf type grpc.gateway.protoc_gen_openapiv2.options.Schema
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • clear

      public Openapiv2.Schema.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • getDefaultInstanceForType

      public Openapiv2.Schema getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public Openapiv2.Schema build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public Openapiv2.Schema buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • clone

      public Openapiv2.Schema.Builder clone()
      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • setField

      public Openapiv2.Schema.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • clearField

      public Openapiv2.Schema.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • clearOneof

      public Openapiv2.Schema.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • setRepeatedField

      public Openapiv2.Schema.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • addRepeatedField

      public Openapiv2.Schema.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • mergeFrom

      public Openapiv2.Schema.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Openapiv2.Schema.Builder>
    • mergeFrom

      public Openapiv2.Schema.Builder mergeFrom(Openapiv2.Schema other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3.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 interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.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 interface Openapiv2.SchemaOrBuilder
      Returns:
      Whether the jsonSchema field is set.
    • getJsonSchema

      public Openapiv2.JSONSchema getJsonSchema()
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
      Specified by:
      getJsonSchema in interface Openapiv2.SchemaOrBuilder
      Returns:
      The jsonSchema.
    • setJsonSchema

      public Openapiv2.Schema.Builder setJsonSchema(Openapiv2.JSONSchema value)
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
    • setJsonSchema

      public Openapiv2.Schema.Builder setJsonSchema(Openapiv2.JSONSchema.Builder builderForValue)
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
    • mergeJsonSchema

      public Openapiv2.Schema.Builder mergeJsonSchema(Openapiv2.JSONSchema value)
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
    • clearJsonSchema

      public Openapiv2.Schema.Builder clearJsonSchema()
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
    • getJsonSchemaBuilder

      public Openapiv2.JSONSchema.Builder getJsonSchemaBuilder()
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
    • getJsonSchemaOrBuilder

      public Openapiv2.JSONSchemaOrBuilder getJsonSchemaOrBuilder()
      .grpc.gateway.protoc_gen_openapiv2.options.JSONSchema json_schema = 1;
      Specified by:
      getJsonSchemaOrBuilder in interface Openapiv2.SchemaOrBuilder
    • getDiscriminator

      public String 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 interface Openapiv2.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 interface Openapiv2.SchemaOrBuilder
      Returns:
      The bytes for discriminator.
    • setDiscriminator

      public Openapiv2.Schema.Builder setDiscriminator(String value)
       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

      public Openapiv2.Schema.Builder 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

      public Openapiv2.Schema.Builder setDiscriminatorBytes(com.google.protobuf.ByteString value)
       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 interface Openapiv2.SchemaOrBuilder
      Returns:
      The readOnly.
    • setReadOnly

      public Openapiv2.Schema.Builder setReadOnly(boolean value)
       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

      public Openapiv2.Schema.Builder 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 interface Openapiv2.SchemaOrBuilder
      Returns:
      Whether the externalDocs field is set.
    • getExternalDocs

      public Openapiv2.ExternalDocumentation getExternalDocs()
       Additional external documentation for this schema.
       
      .grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
      Specified by:
      getExternalDocs in interface Openapiv2.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

      public Openapiv2.Schema.Builder clearExternalDocs()
       Additional external documentation for this schema.
       
      .grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
    • getExternalDocsBuilder

      public Openapiv2.ExternalDocumentation.Builder getExternalDocsBuilder()
       Additional external documentation for this schema.
       
      .grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
    • getExternalDocsOrBuilder

      public Openapiv2.ExternalDocumentationOrBuilder getExternalDocsOrBuilder()
       Additional external documentation for this schema.
       
      .grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 5;
      Specified by:
      getExternalDocsOrBuilder in interface Openapiv2.SchemaOrBuilder
    • getExample

      public String 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 interface Openapiv2.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 interface Openapiv2.SchemaOrBuilder
      Returns:
      The bytes for example.
    • setExample

      public Openapiv2.Schema.Builder setExample(String value)
       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

      public Openapiv2.Schema.Builder 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

      public Openapiv2.Schema.Builder setExampleBytes(com.google.protobuf.ByteString value)
       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.
    • setUnknownFields

      public final Openapiv2.Schema.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>
    • mergeUnknownFields

      public final Openapiv2.Schema.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Openapiv2.Schema.Builder>