java.security
Class KeyFactory
java.lang.Object
java.security.KeyFactory
public class KeyFactory
- extends Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
KeyFactory
protected KeyFactory(KeyFactorySpi keyFacSpi,
Provider provider,
String algorithm)
getInstance
public static KeyFactory getInstance(String algorithm)
throws NoSuchAlgorithmException
- Throws:
NoSuchAlgorithmException
getInstance
public static KeyFactory getInstance(String algorithm,
String provider)
throws NoSuchAlgorithmException,
NoSuchProviderException
- Throws:
NoSuchAlgorithmException
NoSuchProviderException
getInstance
public static KeyFactory getInstance(String algorithm,
Provider provider)
throws NoSuchAlgorithmException
- Throws:
NoSuchAlgorithmException
getProvider
public final Provider getProvider()
getAlgorithm
public final String getAlgorithm()
generatePublic
public final PublicKey generatePublic(KeySpec keySpec)
throws InvalidKeySpecException
- Throws:
InvalidKeySpecException
generatePrivate
public final PrivateKey generatePrivate(KeySpec keySpec)
throws InvalidKeySpecException
- Throws:
InvalidKeySpecException
getKeySpec
public final <T extends KeySpec> T getKeySpec(Key key,
Class<T> keySpec)
throws InvalidKeySpecException
- Throws:
InvalidKeySpecException
translateKey
public final Key translateKey(Key key)
throws InvalidKeyException
- Throws:
InvalidKeyException
Please submit a feedback, bug or feature