@Test @SuppressWarnings("all") public void getAccountBudgetExceptionTest() throws Exception { StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); mockAccountBudgetService.addException(exception); try { AccountBudgetName resourceName = AccountBudgetName.of("[CUSTOMER]", "[ACCOUNT_BUDGET]"); client.getAccountBudget(resourceName); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { } }
public final AccountBudget getAccountBudget(AccountBudgetName resourceName) { GetAccountBudgetRequest request = GetAccountBudgetRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAccountBudget(request); }
AccountBudgetServiceClient implements BackgroundResource { public final AccountBudget getAccountBudget(AccountBudgetName resourceName) { GetAccountBudgetRequest request = GetAccountBudgetRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAccountBudget(request); } }
AccountBudgetServiceClient implements BackgroundResource { public final AccountBudget getAccountBudget(AccountBudgetName resourceName) { GetAccountBudgetRequest request = GetAccountBudgetRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAccountBudget(request); } protected  AccountBudgetServiceClient(AccountBudgetServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AccountBudgetServiceClient(AccountBudgetServiceStub stub); }
AccountBudgetServiceClient implements BackgroundResource { public final AccountBudget getAccountBudget(AccountBudgetName resourceName) { GetAccountBudgetRequest request = GetAccountBudgetRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAccountBudget(request); } protected  AccountBudgetServiceClient(AccountBudgetServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AccountBudgetServiceClient(AccountBudgetServiceStub stub); static final AccountBudgetServiceClient create(); static final AccountBudgetServiceClient create(AccountBudgetServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") static final AccountBudgetServiceClient create(AccountBudgetServiceStub stub); final AccountBudgetServiceSettings getSettings(); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") AccountBudgetServiceStub getStub(); final AccountBudget getAccountBudget(AccountBudgetName resourceName); final AccountBudget getAccountBudget(String resourceName); final AccountBudget getAccountBudget(GetAccountBudgetRequest request); final UnaryCallable<GetAccountBudgetRequest, AccountBudget> getAccountBudgetCallable(); @Override final void close(); @Override void shutdown(); @Override boolean isShutdown(); @Override boolean isTerminated(); @Override void shutdownNow(); @Override boolean awaitTermination(long duration, TimeUnit unit); }
AccountBudgetServiceClient implements BackgroundResource { public final AccountBudget getAccountBudget(AccountBudgetName resourceName) { GetAccountBudgetRequest request = GetAccountBudgetRequest.newBuilder() .setResourceName(resourceName == null ? null : resourceName.toString()) .build(); return getAccountBudget(request); } protected  AccountBudgetServiceClient(AccountBudgetServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected  AccountBudgetServiceClient(AccountBudgetServiceStub stub); static final AccountBudgetServiceClient create(); static final AccountBudgetServiceClient create(AccountBudgetServiceSettings settings); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") static final AccountBudgetServiceClient create(AccountBudgetServiceStub stub); final AccountBudgetServiceSettings getSettings(); @BetaApi("A restructuring of stub classes is planned, so this may break in the future") AccountBudgetServiceStub getStub(); final AccountBudget getAccountBudget(AccountBudgetName resourceName); final AccountBudget getAccountBudget(String resourceName); final AccountBudget getAccountBudget(GetAccountBudgetRequest request); final UnaryCallable<GetAccountBudgetRequest, AccountBudget> getAccountBudgetCallable(); @Override final void close(); @Override void shutdown(); @Override boolean isShutdown(); @Override boolean isTerminated(); @Override void shutdownNow(); @Override boolean awaitTermination(long duration, TimeUnit unit);  }