public class RoleExtractor
extends java.lang.Object
Constructor | Description |
---|---|
RoleExtractor() |
Modifier and Type | Method | Description |
---|---|---|
static java.util.Set<AnonymousId> |
extractAnonymousIds(Role role) |
Extract anon ids from the role.
|
static java.util.Set<com.icodici.crypto.KeyAddress> |
extractKeyAddresses(Role role) |
Extract addresses from the role.
|
static java.util.Set<KeyRecord> |
extractKeyRecords(Role role) |
|
static java.util.Set<com.icodici.crypto.PublicKey> |
extractKeys(Role role) |
Extract keys from the role.
|
static @Nullable com.icodici.crypto.KeyAddress |
extractSimpleAddress(Role role) |
Get an address from the role, if it is just a single one.
|
public static java.util.Set<com.icodici.crypto.PublicKey> extractKeys(Role role)
role
- to extranct keys frompublic static java.util.Set<AnonymousId> extractAnonymousIds(Role role)
role
- to extranct keys frompublic static java.util.Set<com.icodici.crypto.KeyAddress> extractKeyAddresses(Role role)
role
- to extranct keys frompublic static @Nullable com.icodici.crypto.KeyAddress extractSimpleAddress(Role role)
null
if a single address cannot be decided
for the role (like, if there is no addresses/keys discoverable or if there is more than 1 address/key). If the role is bound
to a public key rather than an address, returns its short address.