KeyRep.ReadResolve Method

Definition

Resolve the Key object.

[Android.Runtime.Register("readResolve", "()Ljava/lang/Object;", "GetReadResolveHandler")]
protected virtual Java.Lang.Object? ReadResolve ();
[<Android.Runtime.Register("readResolve", "()Ljava/lang/Object;", "GetReadResolveHandler")>]
abstract member ReadResolve : unit -> Java.Lang.Object
override this.ReadResolve : unit -> Java.Lang.Object

Returns

the resolved Key object

Attributes

Exceptions

if the Type|format combination is not recognized, or the resolution of any key parameter fails.

Remarks

Resolve the Key object.

This method supports three Type/format combinations: <ul> <li> Type.SECRET/"RAW" - returns a SecretKeySpec object constructed using encoded key bytes and algorithm <li> Type.PUBLIC/"X.509" - gets a KeyFactory instance for the key algorithm, constructs an X509EncodedKeySpec with the encoded key bytes, and generates a public key from the spec <li> Type.PRIVATE/"PKCS#8" - gets a KeyFactory instance for the key algorithm, constructs a PKCS8EncodedKeySpec with the encoded key bytes, and generates a private key from the spec </ul>

Java documentation for java.security.KeyRep.readResolve().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to