Skip to content
This repository has been archived by the owner on Sep 25, 2023. It is now read-only.

Commit

Permalink
chore: migrate to microgenerator (#263)
Browse files Browse the repository at this point in the history
This PR was generated using Autosynth. 🌈

Synth log will be available here:
https://source.cloud.google.com/results/invocations/80c05de1-6b0b-4693-8929-76794fcb9efa/targets

- [ ] To automatically regenerate this PR, check this box.

PiperOrigin-RevId: 346372957
Source-Link: googleapis/googleapis@857f70d
PiperOrigin-RevId: 346127853
Source-Link: googleapis/googleapis@59ef1bc
PiperOrigin-RevId: 345067549
Source-Link: googleapis/googleapis@8cfc6c8
PiperOrigin-RevId: 344134135
Source-Link: googleapis/googleapis@b11a87f
  • Loading branch information
yoshi-automation committed Dec 14, 2020
1 parent c7328bf commit 3f4b541
Show file tree
Hide file tree
Showing 13 changed files with 401 additions and 569 deletions.

Large diffs are not rendered by default.

Expand Up @@ -5,14 +5,15 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package com.google.cloud.monitoring.dashboard.v1;

import static com.google.cloud.monitoring.dashboard.v1.DashboardsServiceClient.ListDashboardsPagedResponse;
Expand Down Expand Up @@ -41,7 +42,7 @@
import java.util.List;
import javax.annotation.Generated;

// AUTO-GENERATED DOCUMENTATION AND CLASS
// AUTO-GENERATED DOCUMENTATION AND CLASS.
/**
* Settings class to configure an instance of {@link DashboardsServiceClient}.
*
Expand All @@ -58,23 +59,24 @@
*
* <p>For example, to set the total timeout of createDashboard to 30 seconds:
*
* <pre>
* <code>
* <pre>{@code
* DashboardsServiceSettings.Builder dashboardsServiceSettingsBuilder =
* DashboardsServiceSettings.newBuilder();
* dashboardsServiceSettingsBuilder
* .createDashboardSettings()
* .setRetrySettings(
* dashboardsServiceSettingsBuilder.createDashboardSettings().getRetrySettings().toBuilder()
* dashboardsServiceSettingsBuilder
* .createDashboardSettings()
* .getRetrySettings()
* .toBuilder()
* .setTotalTimeout(Duration.ofSeconds(30))
* .build());
* DashboardsServiceSettings dashboardsServiceSettings = dashboardsServiceSettingsBuilder.build();
* </code>
* </pre>
* }</pre>
*/
@Generated("by gapic-generator")
@BetaApi
@Generated("by gapic-generator-java")
public class DashboardsServiceSettings extends ClientSettings<DashboardsServiceSettings> {

/** Returns the object with the settings used for calls to createDashboard. */
public UnaryCallSettings<CreateDashboardRequest, Dashboard> createDashboardSettings() {
return ((DashboardsServiceStubSettings) getStubSettings()).createDashboardSettings();
Expand Down Expand Up @@ -162,18 +164,15 @@ protected DashboardsServiceSettings(Builder settingsBuilder) throws IOException

/** Builder for DashboardsServiceSettings. */
public static class Builder extends ClientSettings.Builder<DashboardsServiceSettings, Builder> {

protected Builder() throws IOException {
this((ClientContext) null);
this(((ClientContext) null));
}

protected Builder(ClientContext clientContext) {
super(DashboardsServiceStubSettings.newBuilder(clientContext));
}

private static Builder createDefault() {
return new Builder(DashboardsServiceStubSettings.newBuilder());
}

protected Builder(DashboardsServiceSettings settings) {
super(settings.getStubSettings().toBuilder());
}
Expand All @@ -182,11 +181,15 @@ protected Builder(DashboardsServiceStubSettings.Builder stubSettings) {
super(stubSettings);
}

private static Builder createDefault() {
return new Builder(DashboardsServiceStubSettings.newBuilder());
}

public DashboardsServiceStubSettings.Builder getStubSettingsBuilder() {
return ((DashboardsServiceStubSettings.Builder) getStubSettings());
}

// NEXT_MAJOR_VER: remove 'throws Exception'
// NEXT_MAJOR_VER: remove 'throws Exception'.
/**
* Applies the given settings updater function to all of the unary API methods in this service.
*
Expand Down
Expand Up @@ -5,7 +5,7 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
Expand All @@ -15,32 +15,16 @@
*/

/**
* A client to Cloud Monitoring API.
*
* <p>The interfaces provided are listed below, along with usage samples.
* The interfaces provided are listed below, along with usage samples.
*
* <p>======================= DashboardsServiceClient =======================
*
* <p>Service Description: Manages Stackdriver dashboards. A dashboard is an arrangement of data
* display widgets in a specific layout.
*
* <p>Sample for DashboardsServiceClient:
*
* <pre>
* <code>
* try (DashboardsServiceClient dashboardsServiceClient = DashboardsServiceClient.create()) {
* String parent = "";
* Dashboard dashboard = Dashboard.newBuilder().build();
* CreateDashboardRequest request = CreateDashboardRequest.newBuilder()
* .setParent(parent)
* .setDashboard(dashboard)
* .build();
* Dashboard response = dashboardsServiceClient.createDashboard(request);
* }
* </code>
* </pre>
*/
@Generated("by gapic-generator")
@Generated("by gapic-generator-java")
package com.google.cloud.monitoring.dashboard.v1;

import javax.annotation.Generated;
Expand Up @@ -5,19 +5,19 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package com.google.cloud.monitoring.dashboard.v1.stub;

import static com.google.cloud.monitoring.dashboard.v1.DashboardsServiceClient.ListDashboardsPagedResponse;

import com.google.api.core.BetaApi;
import com.google.api.gax.core.BackgroundResource;
import com.google.api.gax.rpc.UnaryCallable;
import com.google.monitoring.dashboard.v1.CreateDashboardRequest;
Expand All @@ -30,14 +30,13 @@
import com.google.protobuf.Empty;
import javax.annotation.Generated;

// AUTO-GENERATED DOCUMENTATION AND CLASS
// AUTO-GENERATED DOCUMENTATION AND CLASS.
/**
* Base stub class for Cloud Monitoring API.
* Base stub class for the DashboardsService service API.
*
* <p>This class is for advanced usage and reflects the underlying API directly.
*/
@Generated("by gapic-generator")
@BetaApi("A restructuring of stub classes is planned, so this may break in the future")
public abstract class DashboardsServiceStub implements BackgroundResource {

public UnaryCallable<CreateDashboardRequest, Dashboard> createDashboardCallable() {
Expand Down

0 comments on commit 3f4b541

Please sign in to comment.