@Test @SuppressWarnings("all") public void getAdGroupLabelTest() { com.google.ads.googleads.v5.services.AdGroupLabelName resourceName2 = com.google.ads.googleads.v5.services.AdGroupLabelName.of("[CUSTOMER]", "[AD_GROUP_LABEL]"); AdGroupLabel expectedResponse = AdGroupLabel.newBuilder().setResourceName(resourceName2.toString()).build(); mockAdGroupLabelService.addResponse(expectedResponse); AdGroupLabelName resourceName = AdGroupLabelName.of("[CUSTOMER]", "[AD_GROUP_LABEL]"); AdGroupLabel actualResponse = client.getAdGroupLabel(resourceName); Assert.assertEquals(expectedResponse, actualResponse); List<AbstractMessage> actualRequests = mockAdGroupLabelService.getRequests(); Assert.assertEquals(1, actualRequests.size()); GetAdGroupLabelRequest actualRequest = (GetAdGroupLabelRequest) actualRequests.get(0); Assert.assertEquals(resourceName, AdGroupLabelName.parse(actualRequest.getResourceName())); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), GaxGrpcProperties.getDefaultApiClientHeaderPattern())); }
public final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName) { GetAdGroupLabelRequest request = GetAdGroupLabelRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAdGroupLabel(request); }
AdGroupLabelServiceClient implements BackgroundResource { public final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName) { GetAdGroupLabelRequest request = GetAdGroupLabelRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAdGroupLabel(request); } }
AdGroupLabelServiceClient implements BackgroundResource { public final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName) { GetAdGroupLabelRequest request = GetAdGroupLabelRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAdGroupLabel(request); } protected  AdGroupLabelServiceClient(AdGroupLabelServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AdGroupLabelServiceClient(AdGroupLabelServiceStub stub); }
AdGroupLabelServiceClient implements BackgroundResource { public final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName) { GetAdGroupLabelRequest request = GetAdGroupLabelRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAdGroupLabel(request); } protected  AdGroupLabelServiceClient(AdGroupLabelServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AdGroupLabelServiceClient(AdGroupLabelServiceStub stub); static final AdGroupLabelServiceClient create(); static final AdGroupLabelServiceClient create(AdGroupLabelServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") static final AdGroupLabelServiceClient create(AdGroupLabelServiceStub stub); final AdGroupLabelServiceSettings getSettings(); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") AdGroupLabelServiceStub getStub(); final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName); final AdGroupLabel getAdGroupLabel(String resourceName); final AdGroupLabel getAdGroupLabel(GetAdGroupLabelRequest request); final UnaryCallable<GetAdGroupLabelRequest, AdGroupLabel> getAdGroupLabelCallable(); final MutateAdGroupLabelsResponse mutateAdGroupLabels(
      String customerId, List<AdGroupLabelOperation> operations); final MutateAdGroupLabelsResponse mutateAdGroupLabels(MutateAdGroupLabelsRequest request); final UnaryCallable<MutateAdGroupLabelsRequest, MutateAdGroupLabelsResponse> mutateAdGroupLabelsCallable(); @Override final void close(); @Override void shutdown(); @Override boolean isShutdown(); @Override boolean isTerminated(); @Override void shutdownNow(); @Override boolean awaitTermination(long duration, TimeUnit unit); }
AdGroupLabelServiceClient implements BackgroundResource { public final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName) { GetAdGroupLabelRequest request = GetAdGroupLabelRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAdGroupLabel(request); } protected  AdGroupLabelServiceClient(AdGroupLabelServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AdGroupLabelServiceClient(AdGroupLabelServiceStub stub); static final AdGroupLabelServiceClient create(); static final AdGroupLabelServiceClient create(AdGroupLabelServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") static final AdGroupLabelServiceClient create(AdGroupLabelServiceStub stub); final AdGroupLabelServiceSettings getSettings(); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") AdGroupLabelServiceStub getStub(); final AdGroupLabel getAdGroupLabel(AdGroupLabelName resourceName); final AdGroupLabel getAdGroupLabel(String resourceName); final AdGroupLabel getAdGroupLabel(GetAdGroupLabelRequest request); final UnaryCallable<GetAdGroupLabelRequest, AdGroupLabel> getAdGroupLabelCallable(); final MutateAdGroupLabelsResponse mutateAdGroupLabels(
      String customerId, List<AdGroupLabelOperation> operations); final MutateAdGroupLabelsResponse mutateAdGroupLabels(MutateAdGroupLabelsRequest request); final UnaryCallable<MutateAdGroupLabelsRequest, MutateAdGroupLabelsResponse> mutateAdGroupLabelsCallable(); @Override final void close(); @Override void shutdown(); @Override boolean isShutdown(); @Override boolean isTerminated(); @Override void shutdownNow(); @Override boolean awaitTermination(long duration, TimeUnit unit);  }