Interface Openapiv2.SwaggerOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
Openapiv2.Swagger
,Openapiv2.Swagger.Builder
- Enclosing class:
- Openapiv2
public static interface Openapiv2.SwaggerOrBuilder
extends com.google.protobuf.MessageOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptionboolean
containsExtensions
(String key) Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification.boolean
containsResponses
(String key) An object to hold responses that can be used across operations.The base path on which the API is served, which is relative to the host.com.google.protobuf.ByteString
The base path on which the API is served, which is relative to the host.getConsumes
(int index) A list of MIME types the APIs can consume.com.google.protobuf.ByteString
getConsumesBytes
(int index) A list of MIME types the APIs can consume.int
A list of MIME types the APIs can consume.A list of MIME types the APIs can consume.Deprecated.int
Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification.Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification.com.google.protobuf.Value
getExtensionsOrDefault
(String key, com.google.protobuf.Value defaultValue) Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification.com.google.protobuf.Value
Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification.Additional external documentation.Additional external documentation.getHost()
The host (name or ip) serving the API.com.google.protobuf.ByteString
The host (name or ip) serving the API.getInfo()
Provides metadata about the API.Provides metadata about the API.getProduces
(int index) A list of MIME types the APIs can produce.com.google.protobuf.ByteString
getProducesBytes
(int index) A list of MIME types the APIs can produce.int
A list of MIME types the APIs can produce.A list of MIME types the APIs can produce.Deprecated.int
An object to hold responses that can be used across operations.An object to hold responses that can be used across operations.getResponsesOrDefault
(String key, Openapiv2.Response defaultValue) An object to hold responses that can be used across operations.An object to hold responses that can be used across operations.getSchemes
(int index) The transfer protocol of the API.int
The transfer protocol of the API.The transfer protocol of the API.int
getSchemesValue
(int index) The transfer protocol of the API.The transfer protocol of the API.getSecurity
(int index) A declaration of which security schemes are applied for the API as a whole.int
A declaration of which security schemes are applied for the API as a whole.Security scheme definitions that can be used across the specification.Security scheme definitions that can be used across the specification.A declaration of which security schemes are applied for the API as a whole.getSecurityOrBuilder
(int index) A declaration of which security schemes are applied for the API as a whole.List<? extends Openapiv2.SecurityRequirementOrBuilder>
A declaration of which security schemes are applied for the API as a whole.Specifies the OpenAPI Specification version being used.com.google.protobuf.ByteString
Specifies the OpenAPI Specification version being used.getTags
(int index) A list of tags for API documentation control.int
A list of tags for API documentation control.A list of tags for API documentation control.getTagsOrBuilder
(int index) A list of tags for API documentation control.List<? extends Openapiv2.TagOrBuilder>
A list of tags for API documentation control.boolean
Additional external documentation.boolean
hasInfo()
Provides metadata about the API.boolean
Security scheme definitions that can be used across the specification.Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
isInitialized
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getSwagger
String getSwagger()Specifies the OpenAPI Specification version being used. It can be used by the OpenAPI UI and other clients to interpret the API listing. The value MUST be "2.0".
string swagger = 1;
- Returns:
- The swagger.
-
getSwaggerBytes
com.google.protobuf.ByteString getSwaggerBytes()Specifies the OpenAPI Specification version being used. It can be used by the OpenAPI UI and other clients to interpret the API listing. The value MUST be "2.0".
string swagger = 1;
- Returns:
- The bytes for swagger.
-
hasInfo
boolean hasInfo()Provides metadata about the API. The metadata can be used by the clients if needed.
.grpc.gateway.protoc_gen_openapiv2.options.Info info = 2;
- Returns:
- Whether the info field is set.
-
getInfo
Openapiv2.Info getInfo()Provides metadata about the API. The metadata can be used by the clients if needed.
.grpc.gateway.protoc_gen_openapiv2.options.Info info = 2;
- Returns:
- The info.
-
getInfoOrBuilder
Openapiv2.InfoOrBuilder getInfoOrBuilder()Provides metadata about the API. The metadata can be used by the clients if needed.
.grpc.gateway.protoc_gen_openapiv2.options.Info info = 2;
-
getHost
String getHost()The host (name or ip) serving the API. This MUST be the host only and does not include the scheme nor sub-paths. It MAY include a port. If the host is not included, the host serving the documentation is to be used (including the port). The host does not support path templating.
string host = 3;
- Returns:
- The host.
-
getHostBytes
com.google.protobuf.ByteString getHostBytes()The host (name or ip) serving the API. This MUST be the host only and does not include the scheme nor sub-paths. It MAY include a port. If the host is not included, the host serving the documentation is to be used (including the port). The host does not support path templating.
string host = 3;
- Returns:
- The bytes for host.
-
getBasePath
String getBasePath()The base path on which the API is served, which is relative to the host. If it is not included, the API is served directly under the host. The value MUST start with a leading slash (/). The basePath does not support path templating. Note that using `base_path` does not change the endpoint paths that are generated in the resulting OpenAPI file. If you wish to use `base_path` with relatively generated OpenAPI paths, the `base_path` prefix must be manually removed from your `google.api.http` paths and your code changed to serve the API from the `base_path`.
string base_path = 4;
- Returns:
- The basePath.
-
getBasePathBytes
com.google.protobuf.ByteString getBasePathBytes()The base path on which the API is served, which is relative to the host. If it is not included, the API is served directly under the host. The value MUST start with a leading slash (/). The basePath does not support path templating. Note that using `base_path` does not change the endpoint paths that are generated in the resulting OpenAPI file. If you wish to use `base_path` with relatively generated OpenAPI paths, the `base_path` prefix must be manually removed from your `google.api.http` paths and your code changed to serve the API from the `base_path`.
string base_path = 4;
- Returns:
- The bytes for basePath.
-
getSchemesList
List<Openapiv2.Scheme> getSchemesList()The transfer protocol of the API. Values MUST be from the list: "http", "https", "ws", "wss". If the schemes is not included, the default scheme to be used is the one used to access the OpenAPI definition itself.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Scheme schemes = 5;
- Returns:
- A list containing the schemes.
-
getSchemesCount
int getSchemesCount()The transfer protocol of the API. Values MUST be from the list: "http", "https", "ws", "wss". If the schemes is not included, the default scheme to be used is the one used to access the OpenAPI definition itself.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Scheme schemes = 5;
- Returns:
- The count of schemes.
-
getSchemes
The transfer protocol of the API. Values MUST be from the list: "http", "https", "ws", "wss". If the schemes is not included, the default scheme to be used is the one used to access the OpenAPI definition itself.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Scheme schemes = 5;
- Parameters:
index
- The index of the element to return.- Returns:
- The schemes at the given index.
-
getSchemesValueList
The transfer protocol of the API. Values MUST be from the list: "http", "https", "ws", "wss". If the schemes is not included, the default scheme to be used is the one used to access the OpenAPI definition itself.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Scheme schemes = 5;
- Returns:
- A list containing the enum numeric values on the wire for schemes.
-
getSchemesValue
int getSchemesValue(int index) The transfer protocol of the API. Values MUST be from the list: "http", "https", "ws", "wss". If the schemes is not included, the default scheme to be used is the one used to access the OpenAPI definition itself.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Scheme schemes = 5;
- Parameters:
index
- The index of the value to return.- Returns:
- The enum numeric value on the wire of schemes at the given index.
-
getConsumesList
A list of MIME types the APIs can consume. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string consumes = 6;
- Returns:
- A list containing the consumes.
-
getConsumesCount
int getConsumesCount()A list of MIME types the APIs can consume. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string consumes = 6;
- Returns:
- The count of consumes.
-
getConsumes
A list of MIME types the APIs can consume. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string consumes = 6;
- Parameters:
index
- The index of the element to return.- Returns:
- The consumes at the given index.
-
getConsumesBytes
com.google.protobuf.ByteString getConsumesBytes(int index) A list of MIME types the APIs can consume. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string consumes = 6;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the consumes at the given index.
-
getProducesList
A list of MIME types the APIs can produce. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string produces = 7;
- Returns:
- A list containing the produces.
-
getProducesCount
int getProducesCount()A list of MIME types the APIs can produce. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string produces = 7;
- Returns:
- The count of produces.
-
getProduces
A list of MIME types the APIs can produce. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string produces = 7;
- Parameters:
index
- The index of the element to return.- Returns:
- The produces at the given index.
-
getProducesBytes
com.google.protobuf.ByteString getProducesBytes(int index) A list of MIME types the APIs can produce. This is global to all APIs but can be overridden on specific API calls. Value MUST be as described under Mime Types.
repeated string produces = 7;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the produces at the given index.
-
getResponsesCount
int getResponsesCount()An object to hold responses that can be used across operations. This property does not define global responses for all operations.
map<string, .grpc.gateway.protoc_gen_openapiv2.options.Response> responses = 10;
-
containsResponses
An object to hold responses that can be used across operations. This property does not define global responses for all operations.
map<string, .grpc.gateway.protoc_gen_openapiv2.options.Response> responses = 10;
-
getResponses
Deprecated.UsegetResponsesMap()
instead. -
getResponsesMap
Map<String,Openapiv2.Response> getResponsesMap()An object to hold responses that can be used across operations. This property does not define global responses for all operations.
map<string, .grpc.gateway.protoc_gen_openapiv2.options.Response> responses = 10;
-
getResponsesOrDefault
An object to hold responses that can be used across operations. This property does not define global responses for all operations.
map<string, .grpc.gateway.protoc_gen_openapiv2.options.Response> responses = 10;
-
getResponsesOrThrow
An object to hold responses that can be used across operations. This property does not define global responses for all operations.
map<string, .grpc.gateway.protoc_gen_openapiv2.options.Response> responses = 10;
-
hasSecurityDefinitions
boolean hasSecurityDefinitions()Security scheme definitions that can be used across the specification.
.grpc.gateway.protoc_gen_openapiv2.options.SecurityDefinitions security_definitions = 11;
- Returns:
- Whether the securityDefinitions field is set.
-
getSecurityDefinitions
Openapiv2.SecurityDefinitions getSecurityDefinitions()Security scheme definitions that can be used across the specification.
.grpc.gateway.protoc_gen_openapiv2.options.SecurityDefinitions security_definitions = 11;
- Returns:
- The securityDefinitions.
-
getSecurityDefinitionsOrBuilder
Openapiv2.SecurityDefinitionsOrBuilder getSecurityDefinitionsOrBuilder()Security scheme definitions that can be used across the specification.
.grpc.gateway.protoc_gen_openapiv2.options.SecurityDefinitions security_definitions = 11;
-
getSecurityList
List<Openapiv2.SecurityRequirement> getSecurityList()A declaration of which security schemes are applied for the API as a whole. The list of values describes alternative security schemes that can be used (that is, there is a logical OR between the security requirements). Individual operations can override this definition.
repeated .grpc.gateway.protoc_gen_openapiv2.options.SecurityRequirement security = 12;
-
getSecurity
A declaration of which security schemes are applied for the API as a whole. The list of values describes alternative security schemes that can be used (that is, there is a logical OR between the security requirements). Individual operations can override this definition.
repeated .grpc.gateway.protoc_gen_openapiv2.options.SecurityRequirement security = 12;
-
getSecurityCount
int getSecurityCount()A declaration of which security schemes are applied for the API as a whole. The list of values describes alternative security schemes that can be used (that is, there is a logical OR between the security requirements). Individual operations can override this definition.
repeated .grpc.gateway.protoc_gen_openapiv2.options.SecurityRequirement security = 12;
-
getSecurityOrBuilderList
List<? extends Openapiv2.SecurityRequirementOrBuilder> getSecurityOrBuilderList()A declaration of which security schemes are applied for the API as a whole. The list of values describes alternative security schemes that can be used (that is, there is a logical OR between the security requirements). Individual operations can override this definition.
repeated .grpc.gateway.protoc_gen_openapiv2.options.SecurityRequirement security = 12;
-
getSecurityOrBuilder
A declaration of which security schemes are applied for the API as a whole. The list of values describes alternative security schemes that can be used (that is, there is a logical OR between the security requirements). Individual operations can override this definition.
repeated .grpc.gateway.protoc_gen_openapiv2.options.SecurityRequirement security = 12;
-
getTagsList
List<Openapiv2.Tag> getTagsList()A list of tags for API documentation control. Tags can be used for logical grouping of operations by resources or any other qualifier.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Tag tags = 13;
-
getTags
A list of tags for API documentation control. Tags can be used for logical grouping of operations by resources or any other qualifier.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Tag tags = 13;
-
getTagsCount
int getTagsCount()A list of tags for API documentation control. Tags can be used for logical grouping of operations by resources or any other qualifier.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Tag tags = 13;
-
getTagsOrBuilderList
List<? extends Openapiv2.TagOrBuilder> getTagsOrBuilderList()A list of tags for API documentation control. Tags can be used for logical grouping of operations by resources or any other qualifier.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Tag tags = 13;
-
getTagsOrBuilder
A list of tags for API documentation control. Tags can be used for logical grouping of operations by resources or any other qualifier.
repeated .grpc.gateway.protoc_gen_openapiv2.options.Tag tags = 13;
-
hasExternalDocs
boolean hasExternalDocs()Additional external documentation.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 14;
- Returns:
- Whether the externalDocs field is set.
-
getExternalDocs
Openapiv2.ExternalDocumentation getExternalDocs()Additional external documentation.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 14;
- Returns:
- The externalDocs.
-
getExternalDocsOrBuilder
Openapiv2.ExternalDocumentationOrBuilder getExternalDocsOrBuilder()Additional external documentation.
.grpc.gateway.protoc_gen_openapiv2.options.ExternalDocumentation external_docs = 14;
-
getExtensionsCount
int getExtensionsCount()Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification. See: https://swagger.io/docs/specification/2-0/swagger-extensions/
map<string, .google.protobuf.Value> extensions = 15;
-
containsExtensions
Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification. See: https://swagger.io/docs/specification/2-0/swagger-extensions/
map<string, .google.protobuf.Value> extensions = 15;
-
getExtensions
Deprecated.UsegetExtensionsMap()
instead. -
getExtensionsMap
Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification. See: https://swagger.io/docs/specification/2-0/swagger-extensions/
map<string, .google.protobuf.Value> extensions = 15;
-
getExtensionsOrDefault
com.google.protobuf.Value getExtensionsOrDefault(String key, com.google.protobuf.Value defaultValue) Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification. See: https://swagger.io/docs/specification/2-0/swagger-extensions/
map<string, .google.protobuf.Value> extensions = 15;
-
getExtensionsOrThrow
Custom properties that start with "x-" such as "x-foo" used to describe extra functionality that is not covered by the standard OpenAPI Specification. See: https://swagger.io/docs/specification/2-0/swagger-extensions/
map<string, .google.protobuf.Value> extensions = 15;
-