Search in sources :

Example 6 with LinkAction

use of io.nem.symbol.sdk.model.transaction.LinkAction in project nem2-sdk-java by nemtech.

the class VotingKeyLinkTransactionMapper method createFactory.

@Override
protected TransactionFactory<VotingKeyLinkTransaction> createFactory(NetworkType networkType, Deadline deadline, VotingKeyLinkTransactionDTO transaction) {
    PublicKey linkedPublicKey = PublicKey.fromHexString(transaction.getLinkedPublicKey());
    LinkAction linkAction = LinkAction.rawValueOf(transaction.getLinkAction().getValue());
    return VotingKeyLinkTransactionFactory.create(networkType, deadline, linkedPublicKey, transaction.getStartEpoch(), transaction.getEndEpoch(), linkAction);
}
Also used : PublicKey(io.nem.symbol.core.crypto.PublicKey) LinkAction(io.nem.symbol.sdk.model.transaction.LinkAction)

Aggregations

PublicKey (io.nem.symbol.core.crypto.PublicKey)6 LinkAction (io.nem.symbol.sdk.model.transaction.LinkAction)6