use of com.hederahashgraph.api.proto.java.Response in project hedera-services by hashgraph.
the class VerifyGetBySolidityIdNotSupported method submitOp.
@Override
protected boolean submitOp(HapiApiSpec spec) {
GetBySolidityIDQuery.Builder op = GetBySolidityIDQuery.newBuilder();
Query query = Query.newBuilder().setGetBySolidityID(op).build();
Response response = spec.clients().getScSvcStub(targetNodeFor(spec), useTls).getBySolidityID(query);
Assertions.assertEquals(NOT_SUPPORTED, response.getGetBySolidityID().getHeader().getNodeTransactionPrecheckCode());
return false;
}
use of com.hederahashgraph.api.proto.java.Response in project hedera-services by hashgraph.
the class VerifyGetStakersNotSupported method submitOp.
@Override
protected boolean submitOp(HapiApiSpec spec) throws Throwable {
CryptoGetStakersQuery.Builder op = CryptoGetStakersQuery.newBuilder().setAccountID(asAccount("0.0.2"));
Query query = Query.newBuilder().setCryptoGetProxyStakers(op).build();
Response response = spec.clients().getCryptoSvcStub(targetNodeFor(spec), useTls).getStakersByAccountID(query);
Assertions.assertEquals(NOT_SUPPORTED, response.getCryptoGetProxyStakers().getHeader().getNodeTransactionPrecheckCode());
return false;
}
use of com.hederahashgraph.api.proto.java.Response in project hedera-services by hashgraph.
the class VerifyGetTokenNftInfosNotSupported method submitOp.
@Override
protected boolean submitOp(HapiApiSpec spec) throws Throwable {
TokenGetNftInfosQuery.Builder op = TokenGetNftInfosQuery.newBuilder().setTokenID(asToken("0.0.1001"));
Query query = Query.newBuilder().setTokenGetNftInfos(op).build();
Response response = spec.clients().getTokenSvcStub(targetNodeFor(spec), useTls).getTokenNftInfos(query);
Assertions.assertEquals(NOT_SUPPORTED, response.getTokenGetNftInfos().getHeader().getNodeTransactionPrecheckCode());
return false;
}
use of com.hederahashgraph.api.proto.java.Response in project hedera-services by hashgraph.
the class HapiGetTokenNftInfo method lookupCostWith.
@Override
protected long lookupCostWith(HapiApiSpec spec, Transaction payment) throws Throwable {
Query query = getTokenNftInfoQuery(spec, payment, true);
Response response = spec.clients().getTokenSvcStub(targetNodeFor(spec), useTls).getTokenNftInfo(query);
return costFrom(response);
}
use of com.hederahashgraph.api.proto.java.Response in project hedera-services by hashgraph.
the class HapiGetTokenNftInfos method lookupCostWith.
@Override
protected long lookupCostWith(HapiApiSpec spec, Transaction payment) throws Throwable {
Query query = getTokenNftInfosQuery(spec, payment, true);
Response response = spec.clients().getTokenSvcStub(targetNodeFor(spec), useTls).getTokenNftInfos(query);
return costFrom(response);
}
Aggregations