public final class KeyPairCredential extends Object implements AlgorithmCredential
NO_CREDENTIALS
Constructor and Description |
---|
KeyPairCredential(KeyPair keyPair)
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
KeyPairCredential |
clone()
Creates and returns a copy of this
Credential . |
boolean |
equals(Object obj) |
String |
getAlgorithm()
Get the algorithm name associated with this credential (will never be
null ). |
KeyPair |
getKeyPair()
Get the key pair.
|
<P extends AlgorithmParameterSpec> |
getParameters(Class<P> paramSpecClass)
Get the algorithm parameters of the given type from this credential.
|
int |
hashCode() |
boolean |
impliesSameParameters(AlgorithmCredential other)
Determine whether the other credential's parameters are implied by this one.
|
boolean |
supportsParameters(Class<? extends AlgorithmParameterSpec> paramSpecClass)
Determine whether this credential instance supports the given algorithm parameter type.
|
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
getParameters, impliesParameters, matches, matches, matches, supportsParameters
canVerify, canVerify, castAndApply, castAndApply, castAndApply, castAs, castAs, castAs, fromKeyStoreEntry, verify, verify
public KeyPairCredential(KeyPair keyPair)
keyPair
- the key pair (may not be null
)public KeyPair getKeyPair()
null
)public boolean supportsParameters(Class<? extends AlgorithmParameterSpec> paramSpecClass)
AlgorithmCredential
supportsParameters
in interface AlgorithmCredential
paramSpecClass
- the parameter specification class (must not be null
)true
if the parameter type is supported, false
otherwisepublic <P extends AlgorithmParameterSpec> P getParameters(Class<P> paramSpecClass)
AlgorithmCredential
getParameters
in interface AlgorithmCredential
paramSpecClass
- the parameter specification class (must not be null
)null
if no parameters are present or available or the given type
was not supported by this credentialpublic boolean impliesSameParameters(AlgorithmCredential other)
AlgorithmCredential
impliesSameParameters
in interface AlgorithmCredential
other
- the other credential (must not be null
)true
if the credentials have matching parameters, false
otherwisepublic String getAlgorithm()
AlgorithmCredential
null
).getAlgorithm
in interface AlgorithmCredential
public KeyPairCredential clone()
AlgorithmCredential
Credential
.clone
in interface AlgorithmCredential
clone
in interface Credential
clone
in class Object
Credential
.Copyright © 2020 JBoss by Red Hat. All rights reserved.