Package org.onyx.api
Class Token.SumBuilder
- Enclosing class:
Token
A builder class for querying token sums in the ledger.
-
Field Summary
Fields inherited from class org.onyx.api.BaseQueryBuilder
next -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddGroupByField(String field) Adds a field on which token values will be summed.getIterable(Client client) Executes the query, returning an iterable over token sums that match the query.Executes the query, returning a page of token sums that match the query.Executes the query, returning a page of token sums that match the query beginning with provided cursor.setGroupBy(List<String> groupBy) Specifies the fields on which token values will be summed.Methods inherited from class org.onyx.api.BaseQueryBuilder
addFilterParameter, setFilter, setFilterParameters, setPageSize
-
Constructor Details
-
SumBuilder
public SumBuilder()
-
-
Method Details
-
getPage
Executes the query, returning a page of token sums that match the query.- Specified by:
getPagein classBaseQueryBuilder<Token.SumBuilder>- Parameters:
client- ledger API connection object- Returns:
- a page of token sums
- Throws:
ChainException
-
getPage
Executes the query, returning a page of token sums that match the query beginning with provided cursor.- Parameters:
client- ledger API connection objectcursor- string representing encoded query object- Returns:
- a page of token sums
- Throws:
ChainException
-
getIterable
Executes the query, returning an iterable over token sums that match the query.- Specified by:
getIterablein classBaseQueryBuilder<Token.SumBuilder>- Parameters:
client- ledger API connection object- Returns:
- an iterable over token sums
- Throws:
ChainException
-
setGroupBy
Specifies the fields on which token values will be summed.- Parameters:
groupBy- a list of token fields- Returns:
- updated builder
-
addGroupByField
Adds a field on which token values will be summed.- Parameters:
field- name of a token field- Returns:
- updated builder
-