Search in sources :

Example 21 with Page

use of io.nem.symbol.sdk.api.Page in project nem2-sdk-java by nemtech.

the class ReceiptRepositoryOkHttpImpl method searchAddressResolutionStatements.

@Override
public Observable<Page<AddressResolutionStatement>> searchAddressResolutionStatements(ResolutionStatementSearchCriteria criteria) {
    BigInteger height = criteria.getHeight();
    Integer pageSize = criteria.getPageSize();
    Integer pageNumber = criteria.getPageNumber();
    String offset = criteria.getOffset();
    Order order = toDto(criteria.getOrder());
    Callable<ResolutionStatementPage> callback = () -> getClient().searchAddressResolutionStatements(height, pageSize, pageNumber, offset, order);
    return exceptionHandling(call(callback).map(page -> this.toPage(page.getPagination(), page.getData().stream().map(mapper::createAddressResolutionStatementFromDto).collect(Collectors.toList()))));
}
Also used : BigInteger(java.math.BigInteger) Order(io.nem.symbol.sdk.openapi.okhttp_gson.model.Order) TransactionStatementPage(io.nem.symbol.sdk.openapi.okhttp_gson.model.TransactionStatementPage) ReceiptTypeEnum(io.nem.symbol.sdk.openapi.okhttp_gson.model.ReceiptTypeEnum) ReceiptRoutesApi(io.nem.symbol.sdk.openapi.okhttp_gson.api.ReceiptRoutesApi) ApiClient(io.nem.symbol.sdk.openapi.okhttp_gson.invoker.ApiClient) Callable(java.util.concurrent.Callable) Collectors(java.util.stream.Collectors) Order(io.nem.symbol.sdk.openapi.okhttp_gson.model.Order) TransactionStatementSearchCriteria(io.nem.symbol.sdk.api.TransactionStatementSearchCriteria) ReceiptType(io.nem.symbol.sdk.model.receipt.ReceiptType) ReceiptRepository(io.nem.symbol.sdk.api.ReceiptRepository) ResolutionStatementPage(io.nem.symbol.sdk.openapi.okhttp_gson.model.ResolutionStatementPage) List(java.util.List) TransactionStatement(io.nem.symbol.sdk.model.receipt.TransactionStatement) ResolutionStatementSearchCriteria(io.nem.symbol.sdk.api.ResolutionStatementSearchCriteria) AddressResolutionStatement(io.nem.symbol.sdk.model.receipt.AddressResolutionStatement) MosaicResolutionStatement(io.nem.symbol.sdk.model.receipt.MosaicResolutionStatement) Observable(io.reactivex.Observable) BigInteger(java.math.BigInteger) Page(io.nem.symbol.sdk.api.Page) BigInteger(java.math.BigInteger) ResolutionStatementPage(io.nem.symbol.sdk.openapi.okhttp_gson.model.ResolutionStatementPage)

Example 22 with Page

use of io.nem.symbol.sdk.api.Page in project nem2-sdk-java by nemtech.

the class TestHelper method createMultisigAccountBonded.

public MultisigAccountInfo createMultisigAccountBonded(RepositoryType type, Account multisigAccount, Account... accounts) {
    AccountRepository accountRepository = getRepositoryFactory(type).createAccountRepository();
    MultisigRepository multisigRepository = getRepositoryFactory(type).createMultisigRepository();
    AccountInfo accountInfo = get(accountRepository.getAccountInfo(multisigAccount.getAddress()));
    System.out.println(getJsonHelper().print(accountInfo));
    if (isMultisig(type, multisigAccount)) {
        System.out.println("Multisig account with address " + multisigAccount.getAddress().plain() + " already exist");
        return get(multisigRepository.getMultisigAccountInfo(multisigAccount.getAddress()));
    }
    System.out.println("Multisig account with address " + multisigAccount.getAddress().plain() + " does not exist. Creating");
    System.out.println("Creating multisg account " + multisigAccount.getAddress().plain());
    List<UnresolvedAddress> additions = Arrays.stream(accounts).map(Account::getAddress).collect(Collectors.toList());
    MultisigAccountModificationTransaction convertIntoMultisigTransaction = MultisigAccountModificationTransactionFactory.create(getNetworkType(), getDeadline(), (byte) 1, (byte) 1, additions, Collections.emptyList()).maxFee(maxFee).build();
    AggregateTransaction aggregateTransaction = AggregateTransactionFactory.createBonded(getNetworkType(), getDeadline(), Collections.singletonList(convertIntoMultisigTransaction.toAggregate(multisigAccount.getPublicAccount()))).maxFee(maxFee).build();
    SignedTransaction signedAggregateTransaction = aggregateTransaction.signTransactionWithCosigners(multisigAccount, Arrays.asList(accounts), getGenerationHash());
    Mosaic hashAmount = getCurrency().createRelative(BigInteger.valueOf(10));
    HashLockTransaction hashLockTransaction = HashLockTransactionFactory.create(getNetworkType(), getDeadline(), hashAmount, BigInteger.valueOf(100), signedAggregateTransaction).maxFee(maxFee).build();
    SignedTransaction signedHashLockTransaction = hashLockTransaction.signWith(multisigAccount, getGenerationHash());
    getTransactionOrFail(getTransactionService(type).announceHashLockAggregateBonded(getListener(type), signedHashLockTransaction, signedAggregateTransaction), aggregateTransaction);
    HashLockRepository hashLockRepository = getRepositoryFactory(type).createHashLockRepository();
    HashLockInfo hashLockInfo = get(hashLockRepository.getHashLock(hashLockTransaction.getHash()));
    Assertions.assertNotNull(hashLockInfo);
    Assertions.assertEquals(multisigAccount.getAddress(), hashLockInfo.getOwnerAddress());
    Assertions.assertEquals(hashAmount.getAmount(), hashLockInfo.getAmount());
    Assertions.assertEquals(LockStatus.UNUSED, hashLockInfo.getStatus());
    Assertions.assertEquals(hashLockTransaction.getHash(), hashLockInfo.getHash());
    Page<HashLockInfo> page = get(hashLockRepository.search(new HashLockSearchCriteria().address(multisigAccount.getAddress())));
    Assertions.assertTrue(page.getData().stream().anyMatch(m -> m.getHash().equals(hashLockTransaction.getHash())));
    Assertions.assertEquals(20, page.getPageSize());
    sleep(1000);
    return get(multisigRepository.getMultisigAccountInfo(multisigAccount.getAddress()));
}
Also used : MultisigAccountInfo(io.nem.symbol.sdk.model.account.MultisigAccountInfo) Arrays(java.util.Arrays) HashLockTransaction(io.nem.symbol.sdk.model.transaction.HashLockTransaction) HashLockRepository(io.nem.symbol.sdk.api.HashLockRepository) Account(io.nem.symbol.sdk.model.account.Account) AccountRepository(io.nem.symbol.sdk.api.AccountRepository) Future(java.util.concurrent.Future) AggregateTransaction(io.nem.symbol.sdk.model.transaction.AggregateTransaction) Pair(org.apache.commons.lang3.tuple.Pair) Duration(java.time.Duration) Map(java.util.Map) AccountInfo(io.nem.symbol.sdk.model.account.AccountInfo) NamespaceRegistrationTransaction(io.nem.symbol.sdk.model.transaction.NamespaceRegistrationTransaction) TransactionType(io.nem.symbol.sdk.model.transaction.TransactionType) TransferTransaction(io.nem.symbol.sdk.model.transaction.TransferTransaction) BigInteger(java.math.BigInteger) Listener(io.nem.symbol.sdk.api.Listener) MosaicDefinitionTransaction(io.nem.symbol.sdk.model.transaction.MosaicDefinitionTransaction) MultisigAccountModificationTransaction(io.nem.symbol.sdk.model.transaction.MultisigAccountModificationTransaction) MosaicDefinitionTransactionFactory(io.nem.symbol.sdk.model.transaction.MosaicDefinitionTransactionFactory) UnresolvedMosaicId(io.nem.symbol.sdk.model.mosaic.UnresolvedMosaicId) NamespaceId(io.nem.symbol.sdk.model.namespace.NamespaceId) BlockDuration(io.nem.symbol.sdk.model.blockchain.BlockDuration) AddressAliasTransactionFactory(io.nem.symbol.sdk.model.transaction.AddressAliasTransactionFactory) MosaicNames(io.nem.symbol.sdk.model.mosaic.MosaicNames) Set(java.util.Set) RepositoryCallException(io.nem.symbol.sdk.api.RepositoryCallException) LockStatus(io.nem.symbol.sdk.model.transaction.LockStatus) MultisigAccountModificationTransactionFactory(io.nem.symbol.sdk.model.transaction.MultisigAccountModificationTransactionFactory) HashLockSearchCriteria(io.nem.symbol.sdk.api.HashLockSearchCriteria) Transaction(io.nem.symbol.sdk.model.transaction.Transaction) Collectors(java.util.stream.Collectors) Executors(java.util.concurrent.Executors) Currency(io.nem.symbol.sdk.model.mosaic.Currency) List(java.util.List) TransferTransactionFactory(io.nem.symbol.sdk.model.transaction.TransferTransactionFactory) JsonHelper(io.nem.symbol.sdk.model.transaction.JsonHelper) ExceptionUtils(io.nem.symbol.core.utils.ExceptionUtils) AggregateTransactionFactory(io.nem.symbol.sdk.model.transaction.AggregateTransactionFactory) Address(io.nem.symbol.sdk.model.account.Address) Page(io.nem.symbol.sdk.api.Page) MosaicSupplyChangeTransactionFactory(io.nem.symbol.sdk.model.transaction.MosaicSupplyChangeTransactionFactory) HashLockTransactionFactory(io.nem.symbol.sdk.model.transaction.HashLockTransactionFactory) Mosaic(io.nem.symbol.sdk.model.mosaic.Mosaic) HashMap(java.util.HashMap) RepositoryFactory(io.nem.symbol.sdk.api.RepositoryFactory) Stored(io.nem.symbol.sdk.model.Stored) LinkedHashMap(java.util.LinkedHashMap) MosaicAliasTransactionFactory(io.nem.symbol.sdk.model.transaction.MosaicAliasTransactionFactory) MultisigRepository(io.nem.symbol.sdk.api.MultisigRepository) TransactionService(io.nem.symbol.sdk.api.TransactionService) MosaicNonce(io.nem.symbol.sdk.model.mosaic.MosaicNonce) SignedTransaction(io.nem.symbol.sdk.model.transaction.SignedTransaction) MosaicSupplyChangeActionType(io.nem.symbol.sdk.model.mosaic.MosaicSupplyChangeActionType) Observable(io.reactivex.Observable) JsonHelperJackson2(io.nem.symbol.sdk.infrastructure.vertx.JsonHelperJackson2) UnresolvedAddress(io.nem.symbol.sdk.model.account.UnresolvedAddress) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) MosaicId(io.nem.symbol.sdk.model.mosaic.MosaicId) AddressAliasTransaction(io.nem.symbol.sdk.model.transaction.AddressAliasTransaction) File(java.io.File) AccountNames(io.nem.symbol.sdk.model.account.AccountNames) TimeUnit(java.util.concurrent.TimeUnit) MosaicAliasTransaction(io.nem.symbol.sdk.model.transaction.MosaicAliasTransaction) TransactionGroup(io.nem.symbol.sdk.model.transaction.TransactionGroup) Deadline(io.nem.symbol.sdk.model.transaction.Deadline) RepositoryFactoryOkHttpImpl(io.nem.symbol.sdk.infrastructure.okhttp.RepositoryFactoryOkHttpImpl) NamespaceRegistrationTransactionFactory(io.nem.symbol.sdk.model.transaction.NamespaceRegistrationTransactionFactory) Assertions(org.junit.jupiter.api.Assertions) HashLockInfo(io.nem.symbol.sdk.model.transaction.HashLockInfo) RepositoryFactoryVertxImpl(io.nem.symbol.sdk.infrastructure.vertx.RepositoryFactoryVertxImpl) NetworkType(io.nem.symbol.sdk.model.network.NetworkType) MosaicFlags(io.nem.symbol.sdk.model.mosaic.MosaicFlags) AliasAction(io.nem.symbol.sdk.model.namespace.AliasAction) MosaicSupplyChangeTransaction(io.nem.symbol.sdk.model.transaction.MosaicSupplyChangeTransaction) Collections(java.util.Collections) TransactionRepository(io.nem.symbol.sdk.api.TransactionRepository) HashLockTransaction(io.nem.symbol.sdk.model.transaction.HashLockTransaction) MultisigRepository(io.nem.symbol.sdk.api.MultisigRepository) UnresolvedAddress(io.nem.symbol.sdk.model.account.UnresolvedAddress) AggregateTransaction(io.nem.symbol.sdk.model.transaction.AggregateTransaction) AccountRepository(io.nem.symbol.sdk.api.AccountRepository) HashLockInfo(io.nem.symbol.sdk.model.transaction.HashLockInfo) MultisigAccountModificationTransaction(io.nem.symbol.sdk.model.transaction.MultisigAccountModificationTransaction) HashLockSearchCriteria(io.nem.symbol.sdk.api.HashLockSearchCriteria) HashLockRepository(io.nem.symbol.sdk.api.HashLockRepository) Mosaic(io.nem.symbol.sdk.model.mosaic.Mosaic) MultisigAccountInfo(io.nem.symbol.sdk.model.account.MultisigAccountInfo) AccountInfo(io.nem.symbol.sdk.model.account.AccountInfo) SignedTransaction(io.nem.symbol.sdk.model.transaction.SignedTransaction)

Example 23 with Page

use of io.nem.symbol.sdk.api.Page in project nem2-sdk-java by nemtech.

the class SecretLockIntegrationTest method secretLockAndProofTransaction.

@ParameterizedTest
@MethodSource("provider")
void secretLockAndProofTransaction(RepositoryType type, LockHashAlgorithm lockHashAlgorithm) {
    RepositoryFactory repositoryFactory = getRepositoryFactory(type);
    byte[] secretSeed = RandomUtils.generateRandomBytes(20);
    String secret = ConvertUtils.toHex(lockHashAlgorithm.hash(secretSeed));
    String storedSecret = ConvertUtils.padHex(secret, LockHashAlgorithm.DEFAULT_SECRET_HEX_SIZE);
    if (lockHashAlgorithm == LockHashAlgorithm.HASH_160) {
        Assertions.assertEquals(LockHashAlgorithm.DEFAULT_SECRET_HEX_SIZE, storedSecret.length());
        Assertions.assertEquals(40, secret.length());
    } else {
        Assertions.assertEquals(LockHashAlgorithm.DEFAULT_SECRET_HEX_SIZE, storedSecret.length());
        Assertions.assertEquals(LockHashAlgorithm.DEFAULT_SECRET_HEX_SIZE, secret.length());
    }
    String proof = ConvertUtils.toHex(secretSeed);
    Account account = config().getNemesisAccount1();
    Account account2 = config().getNemesisAccount2();
    Currency currency = get(repositoryFactory.getNetworkCurrency());
    Mosaic mosaic = currency.createAbsolute(BigInteger.valueOf(1));
    BigInteger amount = mosaic.getAmount();
    BigInteger duration = BigInteger.valueOf(10000);
    SecretLockTransaction secretLockTransaction = SecretLockTransactionFactory.create(getNetworkType(), getDeadline(), mosaic, duration, lockHashAlgorithm, secret, account2.getAddress()).maxFee(maxFee).build();
    announceAndValidate(type, account, secretLockTransaction);
    SecretProofTransaction secretProofTransaction = SecretProofTransactionFactory.create(getNetworkType(), getDeadline(), lockHashAlgorithm, account2.getAddress(), secret, proof).maxFee(maxFee).build();
    SecretProofTransaction secretProofTransactionAnnounced = announceAndValidate(type, account, secretProofTransaction);
    sleep(500);
    Assertions.assertEquals(lockHashAlgorithm, secretProofTransactionAnnounced.getHashType());
    Assertions.assertEquals(account2.getAddress(), secretProofTransactionAnnounced.getRecipient());
    Assertions.assertEquals(storedSecret, secretProofTransactionAnnounced.getSecret());
    Assertions.assertEquals(proof, secretProofTransactionAnnounced.getProof());
    SecretLockRepository hashLockRepository = getRepositoryFactory(type).createSecretLockRepository();
    SecretLockInfo info = get(hashLockRepository.search(new SecretLockSearchCriteria().address(account.getAddress()).secret(storedSecret))).getData().get(0);
    Assertions.assertNotNull(info);
    Assertions.assertEquals(account.getAddress(), info.getOwnerAddress());
    Assertions.assertEquals(account2.getAddress(), info.getRecipientAddress());
    Assertions.assertEquals(amount, info.getAmount());
    Assertions.assertEquals(storedSecret, info.getSecret());
    Assertions.assertEquals(lockHashAlgorithm, info.getHashAlgorithm());
    Assertions.assertEquals(LockStatus.USED, info.getStatus());
    Page<SecretLockInfo> page = get(hashLockRepository.search(new SecretLockSearchCriteria().address(account.getAddress()).order(OrderBy.DESC)));
    Assertions.assertTrue(page.getData().stream().anyMatch(m -> m.getSecret().equals(storedSecret)));
    Assertions.assertEquals(20, page.getPageSize());
    SecretLockInfo infoSearch = page.getData().stream().filter(m -> m.getSecret().equals(storedSecret)).findFirst().get();
    Assertions.assertNotNull(infoSearch);
    Assertions.assertEquals(account.getAddress(), infoSearch.getOwnerAddress());
    Assertions.assertEquals(account2.getAddress(), infoSearch.getRecipientAddress());
    Assertions.assertEquals(amount, infoSearch.getAmount());
    Assertions.assertEquals(lockHashAlgorithm, infoSearch.getHashAlgorithm());
    Assertions.assertEquals(LockStatus.USED, infoSearch.getStatus());
    Assertions.assertEquals(storedSecret, infoSearch.getSecret());
}
Also used : SecretLockTransactionFactory(io.nem.symbol.sdk.model.transaction.SecretLockTransactionFactory) SecretProofTransaction(io.nem.symbol.sdk.model.transaction.SecretProofTransaction) SecretLockInfo(io.nem.symbol.sdk.model.transaction.SecretLockInfo) LockHashAlgorithm(io.nem.symbol.sdk.model.transaction.LockHashAlgorithm) Mosaic(io.nem.symbol.sdk.model.mosaic.Mosaic) Account(io.nem.symbol.sdk.model.account.Account) ConvertUtils(io.nem.symbol.core.utils.ConvertUtils) LockStatus(io.nem.symbol.sdk.model.transaction.LockStatus) Arguments(org.junit.jupiter.params.provider.Arguments) RepositoryFactory(io.nem.symbol.sdk.api.RepositoryFactory) Currency(io.nem.symbol.sdk.model.mosaic.Currency) ArrayList(java.util.ArrayList) SecretLockSearchCriteria(io.nem.symbol.sdk.api.SecretLockSearchCriteria) OrderBy(io.nem.symbol.sdk.api.OrderBy) List(java.util.List) ParameterizedTest(org.junit.jupiter.params.ParameterizedTest) TestInstance(org.junit.jupiter.api.TestInstance) Assertions(org.junit.jupiter.api.Assertions) BigInteger(java.math.BigInteger) SecretLockRepository(io.nem.symbol.sdk.api.SecretLockRepository) Page(io.nem.symbol.sdk.api.Page) SecretProofTransactionFactory(io.nem.symbol.sdk.model.transaction.SecretProofTransactionFactory) SecretLockTransaction(io.nem.symbol.sdk.model.transaction.SecretLockTransaction) MethodSource(org.junit.jupiter.params.provider.MethodSource) Account(io.nem.symbol.sdk.model.account.Account) SecretLockRepository(io.nem.symbol.sdk.api.SecretLockRepository) SecretLockInfo(io.nem.symbol.sdk.model.transaction.SecretLockInfo) SecretProofTransaction(io.nem.symbol.sdk.model.transaction.SecretProofTransaction) SecretLockTransaction(io.nem.symbol.sdk.model.transaction.SecretLockTransaction) SecretLockSearchCriteria(io.nem.symbol.sdk.api.SecretLockSearchCriteria) Currency(io.nem.symbol.sdk.model.mosaic.Currency) BigInteger(java.math.BigInteger) RepositoryFactory(io.nem.symbol.sdk.api.RepositoryFactory) Mosaic(io.nem.symbol.sdk.model.mosaic.Mosaic) ParameterizedTest(org.junit.jupiter.params.ParameterizedTest) MethodSource(org.junit.jupiter.params.provider.MethodSource)

Example 24 with Page

use of io.nem.symbol.sdk.api.Page in project nem2-sdk-java by nemtech.

the class MetadataTransactionServiceTest method shouldCreateNamespaceMetadataTransactionFactory.

@Test
void shouldCreateNamespaceMetadataTransactionFactory() throws Exception {
    BigInteger metadataKey = BigInteger.valueOf(10);
    String oldValue = "The original Message";
    String newValue = "the new Message";
    Metadata metadata = new Metadata("someId", 1, "compositeHash", sourceAddress, targetAccount.getAddress(), metadataKey, MetadataType.NAMESPACE, StringEncoder.getBytes(oldValue), namespaceId.getIdAsHex());
    MetadataSearchCriteria criteria = new MetadataSearchCriteria().sourceAddress(sourceAddress).scopedMetadataKey(metadataKey).targetId(namespaceId).metadataType(MetadataType.NAMESPACE);
    Mockito.when(metadataRepositoryMock.search(Mockito.eq(criteria))).thenReturn(Observable.just(new Page<>(Collections.singletonList(metadata))));
    NamespaceMetadataTransactionFactory result = service.createNamespaceMetadataTransactionFactory(targetAccount.getAddress(), metadataKey, newValue, sourceAddress, namespaceId).toFuture().get();
    Assertions.assertEquals(metadataKey, result.getScopedMetadataKey());
    Assertions.assertNotEquals(oldValue, StringEncoder.getString(result.getValue()));
    Assertions.assertNotEquals(newValue, StringEncoder.getString(result.getValue()));
    Assertions.assertEquals(StringEncoder.getBytes(newValue).length - StringEncoder.getBytes(oldValue).length, result.getValueSizeDelta());
    Assertions.assertEquals(targetAccount.getAddress(), result.getTargetAddress());
    Assertions.assertEquals(namespaceId.getId(), result.getTargetNamespaceId().getId());
    Mockito.verify(metadataRepositoryMock).search(criteria);
}
Also used : MetadataSearchCriteria(io.nem.symbol.sdk.api.MetadataSearchCriteria) Metadata(io.nem.symbol.sdk.model.metadata.Metadata) BigInteger(java.math.BigInteger) Page(io.nem.symbol.sdk.api.Page) NamespaceMetadataTransactionFactory(io.nem.symbol.sdk.model.transaction.NamespaceMetadataTransactionFactory) Test(org.junit.jupiter.api.Test)

Example 25 with Page

use of io.nem.symbol.sdk.api.Page in project nem2-sdk-java by nemtech.

the class MetadataTransactionServiceTest method shouldCreateMosaicMetadataTransactionFactoryUsingAlias.

@Test
void shouldCreateMosaicMetadataTransactionFactoryUsingAlias() throws Exception {
    BigInteger metadataKey = BigInteger.valueOf(10);
    String oldValue = "The original Message";
    String newValue = "the new Message";
    Metadata metadata = new Metadata("someId", 1, "compositeHash", sourceAddress, targetAccount.getAddress(), metadataKey, MetadataType.MOSAIC, StringEncoder.getBytes(oldValue), mosaicId.getIdAsHex());
    MetadataSearchCriteria criteria = new MetadataSearchCriteria().sourceAddress(sourceAddress).scopedMetadataKey(metadataKey).targetId(mosaicId).metadataType(MetadataType.MOSAIC);
    Mockito.when(metadataRepositoryMock.search(Mockito.eq(criteria))).thenReturn(Observable.just(new Page<>(Collections.singletonList(metadata))));
    MosaicMetadataTransactionFactory result = service.createMosaicMetadataTransactionFactory(targetAccount.getAddress(), metadataKey, newValue, sourceAddress, mosaicAlias).toFuture().get();
    Assertions.assertEquals(metadataKey, result.getScopedMetadataKey());
    Assertions.assertNotEquals(oldValue, StringEncoder.getString(result.getValue()));
    Assertions.assertNotEquals(newValue, StringEncoder.getString(result.getValue()));
    Assertions.assertEquals(StringEncoder.getBytes(newValue).length - StringEncoder.getBytes(oldValue).length, result.getValueSizeDelta());
    Assertions.assertEquals(targetAccount.getAddress(), result.getTargetAddress());
    Assertions.assertEquals(mosaicAlias, result.getTargetMosaicId());
    Mockito.verify(metadataRepositoryMock).search(Mockito.eq(criteria));
}
Also used : MetadataSearchCriteria(io.nem.symbol.sdk.api.MetadataSearchCriteria) Metadata(io.nem.symbol.sdk.model.metadata.Metadata) BigInteger(java.math.BigInteger) Page(io.nem.symbol.sdk.api.Page) MosaicMetadataTransactionFactory(io.nem.symbol.sdk.model.transaction.MosaicMetadataTransactionFactory) Test(org.junit.jupiter.api.Test)

Aggregations

Page (io.nem.symbol.sdk.api.Page)26 BigInteger (java.math.BigInteger)18 Observable (io.reactivex.Observable)17 Collectors (java.util.stream.Collectors)17 List (java.util.List)13 ApiClient (io.nem.symbol.sdk.openapi.vertx.invoker.ApiClient)10 Order (io.nem.symbol.sdk.openapi.vertx.model.Order)10 AsyncResult (io.vertx.core.AsyncResult)10 Handler (io.vertx.core.Handler)10 Consumer (java.util.function.Consumer)10 MerkleStateInfo (io.nem.symbol.sdk.model.blockchain.MerkleStateInfo)9 ObjectUtils (org.apache.commons.lang3.ObjectUtils)9 Test (org.junit.jupiter.api.Test)9 MetadataSearchCriteria (io.nem.symbol.sdk.api.MetadataSearchCriteria)8 MapperUtils (io.nem.symbol.core.utils.MapperUtils)7 ReceiptRepository (io.nem.symbol.sdk.api.ReceiptRepository)7 ResolutionStatementSearchCriteria (io.nem.symbol.sdk.api.ResolutionStatementSearchCriteria)7 Address (io.nem.symbol.sdk.model.account.Address)7 AddressResolutionStatement (io.nem.symbol.sdk.model.receipt.AddressResolutionStatement)7 MosaicResolutionStatement (io.nem.symbol.sdk.model.receipt.MosaicResolutionStatement)7