org.polkadot.api.derive.staking.StakingFunctions Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of polkadot-java Show documentation
Show all versions of polkadot-java Show documentation
Java Polkadot API, this is a clone of https://github.com/polkadot-java/api
The newest version!
package org.polkadot.api.derive.staking;
import com.onehilltech.promises.Promise;
import org.polkadot.api.ApiBase;
import org.polkadot.api.Types.ApiInterfacePromise;
import org.polkadot.api.derive.Types;
import org.polkadot.api.derive.balances.BalancesFunctions;
import org.polkadot.types.codec.CodecUtils;
import org.polkadot.types.codec.Vector;
import org.polkadot.types.type.AccountId;
import java.util.List;
import java.util.stream.Collectors;
public class StakingFunctions {
static Promise allBonds(ApiInterfacePromise api, List stashIds) {
List collect = stashIds.stream().map(id -> {
// (api.query.staking.bonded(id) as Observable