Search in sources :

Example 1 with ValidatorInfoGrpcTask

use of wannabit.io.cosmostaion.task.gRpcTask.ValidatorInfoGrpcTask in project cosmostation-android by cosmostation.

the class ValidatorActivity method onInitFetch.

private void onInitFetch() {
    if (mTaskCount > 0)
        return;
    mTaskCount = 6;
    getBaseDao().mGrpcDelegations.clear();
    getBaseDao().mGrpcUndelegations.clear();
    getBaseDao().mGrpcRewards.clear();
    new ValidatorInfoGrpcTask(getBaseApplication(), this, mBaseChain, mValOpAddress).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
    new DelegationsGrpcTask(getBaseApplication(), this, mBaseChain, mAccount).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
    new SelfBondingGrpcTask(getBaseApplication(), this, mBaseChain, mValOpAddress, WKey.convertDpOpAddressToDpAddress(mValOpAddress, BaseChain.getChain(mAccount.baseChain))).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
    new UnDelegationsGrpcTask(getBaseApplication(), this, mBaseChain, mAccount).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
    new AllRewardGrpcTask(getBaseApplication(), this, mBaseChain, mAccount).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
    new ReDelegationsToGrpcTask(getBaseApplication(), this, mBaseChain, mAccount, mValOpAddress).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
}
Also used : DelegationsGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.DelegationsGrpcTask) UnDelegationsGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.UnDelegationsGrpcTask) UnDelegationsGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.UnDelegationsGrpcTask) AllRewardGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.AllRewardGrpcTask) ValidatorInfoGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.ValidatorInfoGrpcTask) ReDelegationsToGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.ReDelegationsToGrpcTask) SelfBondingGrpcTask(wannabit.io.cosmostaion.task.gRpcTask.SelfBondingGrpcTask)

Aggregations

AllRewardGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.AllRewardGrpcTask)1 DelegationsGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.DelegationsGrpcTask)1 ReDelegationsToGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.ReDelegationsToGrpcTask)1 SelfBondingGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.SelfBondingGrpcTask)1 UnDelegationsGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.UnDelegationsGrpcTask)1 ValidatorInfoGrpcTask (wannabit.io.cosmostaion.task.gRpcTask.ValidatorInfoGrpcTask)1