Class ProjectsSettings


  • @Generated("by gapic-generator-java")
    public class ProjectsSettings
    extends com.google.api.gax.rpc.ClientSettings<ProjectsSettings>
    Settings class to configure an instance of ProjectsClient.

    The default instance has everything set to sensible defaults:

    • The default service address (compute.googleapis.com) and default port (443) are used.
    • Credentials are acquired automatically through Application Default Credentials.
    • Retries are configured for idempotent methods but not for non-idempotent methods.

    The builder of this class is recursive, so contained classes are themselves builders. When build() is called, the tree of builders is called to create the complete settings object.

    For example, to set the total timeout of get to 30 seconds:

    
     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     ProjectsSettings.Builder projectsSettingsBuilder = ProjectsSettings.newBuilder();
     projectsSettingsBuilder
         .getSettings()
         .setRetrySettings(
             projectsSettingsBuilder
                 .getSettings()
                 .getRetrySettings()
                 .toBuilder()
                 .setTotalTimeout(Duration.ofSeconds(30))
                 .build());
     ProjectsSettings projectsSettings = projectsSettingsBuilder.build();
     
    • Method Detail

      • disableXpnHostSettings

        public com.google.api.gax.rpc.UnaryCallSettings<DisableXpnHostProjectRequest,​Operation> disableXpnHostSettings()
        Returns the object with the settings used for calls to disableXpnHost.
      • disableXpnHostOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<DisableXpnHostProjectRequest,​Operation,​Operation> disableXpnHostOperationSettings()
        Returns the object with the settings used for calls to disableXpnHost.
      • disableXpnResourceSettings

        public com.google.api.gax.rpc.UnaryCallSettings<DisableXpnResourceProjectRequest,​Operation> disableXpnResourceSettings()
        Returns the object with the settings used for calls to disableXpnResource.
      • disableXpnResourceOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<DisableXpnResourceProjectRequest,​Operation,​Operation> disableXpnResourceOperationSettings()
        Returns the object with the settings used for calls to disableXpnResource.
      • enableXpnHostSettings

        public com.google.api.gax.rpc.UnaryCallSettings<EnableXpnHostProjectRequest,​Operation> enableXpnHostSettings()
        Returns the object with the settings used for calls to enableXpnHost.
      • enableXpnHostOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<EnableXpnHostProjectRequest,​Operation,​Operation> enableXpnHostOperationSettings()
        Returns the object with the settings used for calls to enableXpnHost.
      • enableXpnResourceSettings

        public com.google.api.gax.rpc.UnaryCallSettings<EnableXpnResourceProjectRequest,​Operation> enableXpnResourceSettings()
        Returns the object with the settings used for calls to enableXpnResource.
      • enableXpnResourceOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<EnableXpnResourceProjectRequest,​Operation,​Operation> enableXpnResourceOperationSettings()
        Returns the object with the settings used for calls to enableXpnResource.
      • getSettings

        public com.google.api.gax.rpc.UnaryCallSettings<GetProjectRequest,​Project> getSettings()
        Returns the object with the settings used for calls to get.
      • getXpnHostSettings

        public com.google.api.gax.rpc.UnaryCallSettings<GetXpnHostProjectRequest,​Project> getXpnHostSettings()
        Returns the object with the settings used for calls to getXpnHost.
      • moveDiskSettings

        public com.google.api.gax.rpc.UnaryCallSettings<MoveDiskProjectRequest,​Operation> moveDiskSettings()
        Returns the object with the settings used for calls to moveDisk.
      • moveDiskOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<MoveDiskProjectRequest,​Operation,​Operation> moveDiskOperationSettings()
        Returns the object with the settings used for calls to moveDisk.
      • moveInstanceSettings

        public com.google.api.gax.rpc.UnaryCallSettings<MoveInstanceProjectRequest,​Operation> moveInstanceSettings()
        Returns the object with the settings used for calls to moveInstance.
      • moveInstanceOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<MoveInstanceProjectRequest,​Operation,​Operation> moveInstanceOperationSettings()
        Returns the object with the settings used for calls to moveInstance.
      • setCommonInstanceMetadataSettings

        public com.google.api.gax.rpc.UnaryCallSettings<SetCommonInstanceMetadataProjectRequest,​Operation> setCommonInstanceMetadataSettings()
        Returns the object with the settings used for calls to setCommonInstanceMetadata.
      • setCommonInstanceMetadataOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<SetCommonInstanceMetadataProjectRequest,​Operation,​Operation> setCommonInstanceMetadataOperationSettings()
        Returns the object with the settings used for calls to setCommonInstanceMetadata.
      • setDefaultNetworkTierSettings

        public com.google.api.gax.rpc.UnaryCallSettings<SetDefaultNetworkTierProjectRequest,​Operation> setDefaultNetworkTierSettings()
        Returns the object with the settings used for calls to setDefaultNetworkTier.
      • setDefaultNetworkTierOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<SetDefaultNetworkTierProjectRequest,​Operation,​Operation> setDefaultNetworkTierOperationSettings()
        Returns the object with the settings used for calls to setDefaultNetworkTier.
      • setUsageExportBucketSettings

        public com.google.api.gax.rpc.UnaryCallSettings<SetUsageExportBucketProjectRequest,​Operation> setUsageExportBucketSettings()
        Returns the object with the settings used for calls to setUsageExportBucket.
      • setUsageExportBucketOperationSettings

        public com.google.api.gax.rpc.OperationCallSettings<SetUsageExportBucketProjectRequest,​Operation,​Operation> setUsageExportBucketOperationSettings()
        Returns the object with the settings used for calls to setUsageExportBucket.
      • defaultExecutorProviderBuilder

        public static com.google.api.gax.core.InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder()
        Returns a builder for the default ExecutorProvider for this service.
      • getDefaultEndpoint

        public static String getDefaultEndpoint()
        Returns the default service endpoint.
      • getDefaultServiceScopes

        public static List<String> getDefaultServiceScopes()
        Returns the default service scopes.
      • defaultCredentialsProviderBuilder

        public static com.google.api.gax.core.GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder()
        Returns a builder for the default credentials for this service.
      • defaultHttpJsonTransportProviderBuilder

        public static com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider.Builder defaultHttpJsonTransportProviderBuilder()
        Returns a builder for the default ChannelProvider for this service.
      • defaultTransportChannelProvider

        public static com.google.api.gax.rpc.TransportChannelProvider defaultTransportChannelProvider()
      • defaultApiClientHeaderProviderBuilder

        @BetaApi("The surface for customizing headers is not stable yet and may change in the future.")
        public static com.google.api.gax.rpc.ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder()
      • newBuilder

        public static ProjectsSettings.Builder newBuilder​(com.google.api.gax.rpc.ClientContext clientContext)
        Returns a new builder for this class.
      • toBuilder

        public ProjectsSettings.Builder toBuilder()
        Returns a builder containing all the values of this settings class.
        Specified by:
        toBuilder in class com.google.api.gax.rpc.ClientSettings<ProjectsSettings>