Search in sources :

Example 11 with TaskManager

use of run.wallet.iota.api.TaskManager in project run-wallet-android by runplay.

the class AppService method replayBundleTransaction.

public static void replayBundleTransaction(Context context, Seeds.Seed seed, String hash, String refreshCallAddress) {
    if (Validator.isValidCaller() && Store.getCurrentSeed() != null) {
        ReplayBundleRequest rtr = new ReplayBundleRequest(seed, hash, refreshCallAddress);
        TaskManager rt = new TaskManager(SERVICE);
        runTask(rt, rtr);
    }
}
Also used : TaskManager(run.wallet.iota.api.TaskManager) ReplayBundleRequest(run.wallet.iota.api.requests.ReplayBundleRequest)

Example 12 with TaskManager

use of run.wallet.iota.api.TaskManager in project run-wallet-android by runplay.

the class AppService method auditAddressesWithDelay.

public static void auditAddressesWithDelay(Context context, Seeds.Seed seed) {
    if (Validator.isValidCaller() && seed != null) {
        if (AppService.countSeedRunningTasks(seed) == 0) {
            TaskManager rt = new TaskManager(SERVICE);
            AuditAddressesRequest gtr = new AuditAddressesRequest(seed);
            runTask(rt, gtr);
        }
    }
}
Also used : TaskManager(run.wallet.iota.api.TaskManager) AuditAddressesRequest(run.wallet.iota.api.requests.AuditAddressesRequest)

Example 13 with TaskManager

use of run.wallet.iota.api.TaskManager in project run-wallet-android by runplay.

the class AppService method updateExchangeRates.

public static void updateExchangeRates(Context context) {
    long now = System.currentTimeMillis();
    if (lastExchangeRateCall == 0 || now > lastExchangeRateCall + timeoutExchangeRates) {
        lastExchangeRateCall = now;
        TaskManager rt = new TaskManager(SERVICE);
        WebGetExchangeRatesRequest nir = new WebGetExchangeRatesRequest();
        runBasicTask(rt, nir);
    }
}
Also used : TaskManager(run.wallet.iota.api.TaskManager) WebGetExchangeRatesRequest(run.wallet.iota.api.requests.WebGetExchangeRatesRequest)

Example 14 with TaskManager

use of run.wallet.iota.api.TaskManager in project run-wallet-android by runplay.

the class AppService method getAccountDataSingleAddress.

public static void getAccountDataSingleAddress(Context context, Seeds.Seed seed, String address) {
    if (Validator.isValidCaller() && Store.getCurrentSeed() != null) {
        if (SERVICE != null && !isGetAccountDataRunning(Store.getCurrentSeed())) {
            TaskManager rt = new TaskManager(SERVICE);
            GetAccountDataRequest gna = new GetAccountDataRequest(seed);
            gna.setSingleAddressRefresh(address);
            runTask(rt, gna);
        }
    }
}
Also used : TaskManager(run.wallet.iota.api.TaskManager) GetAccountDataRequest(run.wallet.iota.api.requests.GetAccountDataRequest)

Example 15 with TaskManager

use of run.wallet.iota.api.TaskManager in project run-wallet-android by runplay.

the class AppService method getFirstTimeLoad.

public static void getFirstTimeLoad(Context context) {
    if (Validator.isValidCaller() && Store.getCurrentSeed() != null) {
        TaskManager rt = new TaskManager(SERVICE);
        GetFirstLoadRequest gna = new GetFirstLoadRequest(Store.getCurrentSeed());
        runTask(rt, gna);
    }
}
Also used : TaskManager(run.wallet.iota.api.TaskManager) GetFirstLoadRequest(run.wallet.iota.api.requests.GetFirstLoadRequest)

Aggregations

TaskManager (run.wallet.iota.api.TaskManager)24 SendTransferRequest (run.wallet.iota.api.requests.SendTransferRequest)4 AuditAddressesRequest (run.wallet.iota.api.requests.AuditAddressesRequest)2 AutoNudgeRequest (run.wallet.iota.api.requests.AutoNudgeRequest)2 GetAccountDataRequest (run.wallet.iota.api.requests.GetAccountDataRequest)2 NodeInfoRequest (run.wallet.iota.api.requests.NodeInfoRequest)2 RefreshUsedAddressesRequest (run.wallet.iota.api.requests.RefreshUsedAddressesRequest)2 AddressSecurityChangeRequest (run.wallet.iota.api.requests.AddressSecurityChangeRequest)1 GetFirstLoadRequest (run.wallet.iota.api.requests.GetFirstLoadRequest)1 GetNeighborsRequest (run.wallet.iota.api.requests.GetNeighborsRequest)1 GetNewAddressRequest (run.wallet.iota.api.requests.GetNewAddressRequest)1 MessageFirstLoadRequest (run.wallet.iota.api.requests.MessageFirstLoadRequest)1 MessageNewAddressRequest (run.wallet.iota.api.requests.MessageNewAddressRequest)1 MessageSendRequest (run.wallet.iota.api.requests.MessageSendRequest)1 NudgeRequest (run.wallet.iota.api.requests.NudgeRequest)1 ReplayBundleRequest (run.wallet.iota.api.requests.ReplayBundleRequest)1 WebGetExchangeRatesHistoryRequest (run.wallet.iota.api.requests.WebGetExchangeRatesHistoryRequest)1 WebGetExchangeRatesRequest (run.wallet.iota.api.requests.WebGetExchangeRatesRequest)1