Class ApiConfig

  • All Implemented Interfaces:
    ApiConfigOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class ApiConfig
    extends com.google.protobuf.GeneratedMessageV3
    implements ApiConfigOrBuilder
     An API Configuration is a combination of settings for both the Managed
     Service and Gateways serving this API Config.
     
    Protobuf type google.cloud.apigateway.v1.ApiConfig
    See Also:
    Serialized Form
    • Field Detail

      • CREATE_TIME_FIELD_NUMBER

        public static final int CREATE_TIME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • UPDATE_TIME_FIELD_NUMBER

        public static final int UPDATE_TIME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • DISPLAY_NAME_FIELD_NUMBER

        public static final int DISPLAY_NAME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • GATEWAY_SERVICE_ACCOUNT_FIELD_NUMBER

        public static final int GATEWAY_SERVICE_ACCOUNT_FIELD_NUMBER
        See Also:
        Constant Field Values
      • SERVICE_CONFIG_ID_FIELD_NUMBER

        public static final int SERVICE_CONFIG_ID_FIELD_NUMBER
        See Also:
        Constant Field Values
      • OPENAPI_DOCUMENTS_FIELD_NUMBER

        public static final int OPENAPI_DOCUMENTS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • GRPC_SERVICES_FIELD_NUMBER

        public static final int GRPC_SERVICES_FIELD_NUMBER
        See Also:
        Constant Field Values
      • MANAGED_SERVICE_CONFIGS_FIELD_NUMBER

        public static final int MANAGED_SERVICE_CONFIGS_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

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

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getName

        public String getName()
         Output only. Resource name of the API Config.
         Format: projects/{project}/locations/global/apis/{api}/configs/{api_config}
         
        string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getName in interface ApiConfigOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Output only. Resource name of the API Config.
         Format: projects/{project}/locations/global/apis/{api}/configs/{api_config}
         
        string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getNameBytes in interface ApiConfigOrBuilder
        Returns:
        The bytes for name.
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. Created time.
         
        .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCreateTime in interface ApiConfigOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. Created time.
         
        .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTime in interface ApiConfigOrBuilder
        Returns:
        The createTime.
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. Created time.
         
        .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTimeOrBuilder in interface ApiConfigOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. Updated time.
         
        .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasUpdateTime in interface ApiConfigOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. Updated time.
         
        .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTime in interface ApiConfigOrBuilder
        Returns:
        The updateTime.
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. Updated time.
         
        .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTimeOrBuilder in interface ApiConfigOrBuilder
      • getLabelsCount

        public int getLabelsCount()
        Description copied from interface: ApiConfigOrBuilder
         Optional. Resource labels to represent user-provided metadata.
         Refer to cloud documentation on labels for more details.
         https://cloud.google.com/compute/docs/labeling-resources
         
        map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsCount in interface ApiConfigOrBuilder
      • containsLabels

        public boolean containsLabels​(String key)
         Optional. Resource labels to represent user-provided metadata.
         Refer to cloud documentation on labels for more details.
         https://cloud.google.com/compute/docs/labeling-resources
         
        map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        containsLabels in interface ApiConfigOrBuilder
      • getLabelsMap

        public Map<String,​String> getLabelsMap()
         Optional. Resource labels to represent user-provided metadata.
         Refer to cloud documentation on labels for more details.
         https://cloud.google.com/compute/docs/labeling-resources
         
        map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsMap in interface ApiConfigOrBuilder
      • getLabelsOrDefault

        public String getLabelsOrDefault​(String key,
                                         String defaultValue)
         Optional. Resource labels to represent user-provided metadata.
         Refer to cloud documentation on labels for more details.
         https://cloud.google.com/compute/docs/labeling-resources
         
        map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsOrDefault in interface ApiConfigOrBuilder
      • getLabelsOrThrow

        public String getLabelsOrThrow​(String key)
         Optional. Resource labels to represent user-provided metadata.
         Refer to cloud documentation on labels for more details.
         https://cloud.google.com/compute/docs/labeling-resources
         
        map<string, string> labels = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsOrThrow in interface ApiConfigOrBuilder
      • getDisplayName

        public String getDisplayName()
         Optional. Display name.
         
        string display_name = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getDisplayName in interface ApiConfigOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         Optional. Display name.
         
        string display_name = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getDisplayNameBytes in interface ApiConfigOrBuilder
        Returns:
        The bytes for displayName.
      • getGatewayServiceAccount

        public String getGatewayServiceAccount()
         Immutable. The Google Cloud IAM Service Account that Gateways serving this config
         should use to authenticate to other services. This may either be the
         Service Account's email
         (`{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`) or its full resource
         name (`projects/{PROJECT}/accounts/{UNIQUE_ID}`). This is most often used
         when the service is a GCP resource such as a Cloud Run Service or an
         IAP-secured service.
         
        string gateway_service_account = 14 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }
        Specified by:
        getGatewayServiceAccount in interface ApiConfigOrBuilder
        Returns:
        The gatewayServiceAccount.
      • getGatewayServiceAccountBytes

        public com.google.protobuf.ByteString getGatewayServiceAccountBytes()
         Immutable. The Google Cloud IAM Service Account that Gateways serving this config
         should use to authenticate to other services. This may either be the
         Service Account's email
         (`{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`) or its full resource
         name (`projects/{PROJECT}/accounts/{UNIQUE_ID}`). This is most often used
         when the service is a GCP resource such as a Cloud Run Service or an
         IAP-secured service.
         
        string gateway_service_account = 14 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }
        Specified by:
        getGatewayServiceAccountBytes in interface ApiConfigOrBuilder
        Returns:
        The bytes for gatewayServiceAccount.
      • getServiceConfigId

        public String getServiceConfigId()
         Output only. The ID of the associated Service Config (
         https://cloud.google.com/service-infrastructure/docs/glossary#config).
         
        string service_config_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getServiceConfigId in interface ApiConfigOrBuilder
        Returns:
        The serviceConfigId.
      • getServiceConfigIdBytes

        public com.google.protobuf.ByteString getServiceConfigIdBytes()
         Output only. The ID of the associated Service Config (
         https://cloud.google.com/service-infrastructure/docs/glossary#config).
         
        string service_config_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getServiceConfigIdBytes in interface ApiConfigOrBuilder
        Returns:
        The bytes for serviceConfigId.
      • getStateValue

        public int getStateValue()
         Output only. State of the API Config.
         
        .google.cloud.apigateway.v1.ApiConfig.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getStateValue in interface ApiConfigOrBuilder
        Returns:
        The enum numeric value on the wire for state.
      • getState

        public ApiConfig.State getState()
         Output only. State of the API Config.
         
        .google.cloud.apigateway.v1.ApiConfig.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getState in interface ApiConfigOrBuilder
        Returns:
        The state.
      • getOpenapiDocumentsList

        public List<ApiConfig.OpenApiDocument> getOpenapiDocumentsList()
         Optional. OpenAPI specification documents. If specified, grpc_services and
         managed_service_configs must not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.OpenApiDocument openapi_documents = 9 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOpenapiDocumentsList in interface ApiConfigOrBuilder
      • getOpenapiDocumentsOrBuilderList

        public List<? extends ApiConfig.OpenApiDocumentOrBuilder> getOpenapiDocumentsOrBuilderList()
         Optional. OpenAPI specification documents. If specified, grpc_services and
         managed_service_configs must not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.OpenApiDocument openapi_documents = 9 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOpenapiDocumentsOrBuilderList in interface ApiConfigOrBuilder
      • getOpenapiDocumentsCount

        public int getOpenapiDocumentsCount()
         Optional. OpenAPI specification documents. If specified, grpc_services and
         managed_service_configs must not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.OpenApiDocument openapi_documents = 9 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOpenapiDocumentsCount in interface ApiConfigOrBuilder
      • getOpenapiDocuments

        public ApiConfig.OpenApiDocument getOpenapiDocuments​(int index)
         Optional. OpenAPI specification documents. If specified, grpc_services and
         managed_service_configs must not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.OpenApiDocument openapi_documents = 9 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOpenapiDocuments in interface ApiConfigOrBuilder
      • getOpenapiDocumentsOrBuilder

        public ApiConfig.OpenApiDocumentOrBuilder getOpenapiDocumentsOrBuilder​(int index)
         Optional. OpenAPI specification documents. If specified, grpc_services and
         managed_service_configs must not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.OpenApiDocument openapi_documents = 9 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOpenapiDocumentsOrBuilder in interface ApiConfigOrBuilder
      • getGrpcServicesList

        public List<ApiConfig.GrpcServiceDefinition> getGrpcServicesList()
         Optional. gRPC service definition files. If specified, openapi_documents must
         not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.GrpcServiceDefinition grpc_services = 10 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getGrpcServicesList in interface ApiConfigOrBuilder
      • getGrpcServicesCount

        public int getGrpcServicesCount()
         Optional. gRPC service definition files. If specified, openapi_documents must
         not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.GrpcServiceDefinition grpc_services = 10 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getGrpcServicesCount in interface ApiConfigOrBuilder
      • getGrpcServices

        public ApiConfig.GrpcServiceDefinition getGrpcServices​(int index)
         Optional. gRPC service definition files. If specified, openapi_documents must
         not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.GrpcServiceDefinition grpc_services = 10 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getGrpcServices in interface ApiConfigOrBuilder
      • getGrpcServicesOrBuilder

        public ApiConfig.GrpcServiceDefinitionOrBuilder getGrpcServicesOrBuilder​(int index)
         Optional. gRPC service definition files. If specified, openapi_documents must
         not be included.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.GrpcServiceDefinition grpc_services = 10 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getGrpcServicesOrBuilder in interface ApiConfigOrBuilder
      • getManagedServiceConfigsList

        public List<ApiConfig.File> getManagedServiceConfigsList()
         Optional. Service Configuration files. At least one must be included when using gRPC
         service definitions. See
         https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#service_configuration_overview
         for the expected file contents.
        
         If multiple files are specified, the files are merged with the following
         rules:
         * All singular scalar fields are merged using "last one wins" semantics in
         the order of the files uploaded.
         * Repeated fields are concatenated.
         * Singular embedded messages are merged using these rules for nested
         fields.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.File managed_service_configs = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getManagedServiceConfigsList in interface ApiConfigOrBuilder
      • getManagedServiceConfigsOrBuilderList

        public List<? extends ApiConfig.FileOrBuilder> getManagedServiceConfigsOrBuilderList()
         Optional. Service Configuration files. At least one must be included when using gRPC
         service definitions. See
         https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#service_configuration_overview
         for the expected file contents.
        
         If multiple files are specified, the files are merged with the following
         rules:
         * All singular scalar fields are merged using "last one wins" semantics in
         the order of the files uploaded.
         * Repeated fields are concatenated.
         * Singular embedded messages are merged using these rules for nested
         fields.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.File managed_service_configs = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getManagedServiceConfigsOrBuilderList in interface ApiConfigOrBuilder
      • getManagedServiceConfigsCount

        public int getManagedServiceConfigsCount()
         Optional. Service Configuration files. At least one must be included when using gRPC
         service definitions. See
         https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#service_configuration_overview
         for the expected file contents.
        
         If multiple files are specified, the files are merged with the following
         rules:
         * All singular scalar fields are merged using "last one wins" semantics in
         the order of the files uploaded.
         * Repeated fields are concatenated.
         * Singular embedded messages are merged using these rules for nested
         fields.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.File managed_service_configs = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getManagedServiceConfigsCount in interface ApiConfigOrBuilder
      • getManagedServiceConfigs

        public ApiConfig.File getManagedServiceConfigs​(int index)
         Optional. Service Configuration files. At least one must be included when using gRPC
         service definitions. See
         https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#service_configuration_overview
         for the expected file contents.
        
         If multiple files are specified, the files are merged with the following
         rules:
         * All singular scalar fields are merged using "last one wins" semantics in
         the order of the files uploaded.
         * Repeated fields are concatenated.
         * Singular embedded messages are merged using these rules for nested
         fields.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.File managed_service_configs = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getManagedServiceConfigs in interface ApiConfigOrBuilder
      • getManagedServiceConfigsOrBuilder

        public ApiConfig.FileOrBuilder getManagedServiceConfigsOrBuilder​(int index)
         Optional. Service Configuration files. At least one must be included when using gRPC
         service definitions. See
         https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#service_configuration_overview
         for the expected file contents.
        
         If multiple files are specified, the files are merged with the following
         rules:
         * All singular scalar fields are merged using "last one wins" semantics in
         the order of the files uploaded.
         * Repeated fields are concatenated.
         * Singular embedded messages are merged using these rules for nested
         fields.
         
        repeated .google.cloud.apigateway.v1.ApiConfig.File managed_service_configs = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getManagedServiceConfigsOrBuilder in interface ApiConfigOrBuilder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static ApiConfig parseFrom​(ByteBuffer data)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(ByteBuffer data,
                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(com.google.protobuf.ByteString data)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(com.google.protobuf.ByteString data,
                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(byte[] data)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(byte[] data,
                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ApiConfig parseFrom​(com.google.protobuf.CodedInputStream input,
                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                   throws IOException
        Throws:
        IOException
      • newBuilderForType

        public ApiConfig.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public ApiConfig.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected ApiConfig.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static ApiConfig getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<ApiConfig> parser()
      • getParserForType

        public com.google.protobuf.Parser<ApiConfig> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public ApiConfig getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder