Cipher.GetInstance Cipher.GetInstance Method

Definition

Overloads

GetInstance(String) GetInstance(String)

Creates a new Cipher for the specified transformation.

GetInstance(String, Provider) GetInstance(String, Provider)

Creates a new cipher for the specified transformation.

GetInstance(String, String) GetInstance(String, String)

Creates a new cipher for the specified transformation provided by the specified provider.

GetInstance(String) GetInstance(String)

Creates a new Cipher for the specified transformation.

[Android.Runtime.Register("getInstance", "(Ljava/lang/String;)Ljavax/crypto/Cipher;", "")]
public static Javax.Crypto.Cipher GetInstance (string transformation);
static member GetInstance : string -> Javax.Crypto.Cipher

Parameters

transformation
String String

the name of the transformation to create a cipher for.

Returns

Exceptions

if no installed provider can provide the transformation, or it is null, empty or in an invalid format.

if no installed provider can provide the padding scheme in the transformation.

Remarks

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.

GetInstance(String, Provider) GetInstance(String, Provider)

Creates a new cipher for the specified transformation.

[Android.Runtime.Register("getInstance", "(Ljava/lang/String;Ljava/security/Provider;)Ljavax/crypto/Cipher;", "")]
public static Javax.Crypto.Cipher GetInstance (string transformation, Java.Security.Provider provider);
static member GetInstance : string * Java.Security.Provider -> Javax.Crypto.Cipher

Parameters

transformation
String String

the name of the transformation to create a cipher for.

provider
Provider Provider

the provider to ask for the transformation.

Returns

Exceptions

if the specified provider can not provide the transformation, or it is null, empty or in an invalid format.

if the requested padding scheme in the transformation is not available.

Remarks

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.

GetInstance(String, String) GetInstance(String, String)

Creates a new cipher for the specified transformation provided by the specified provider.

[Android.Runtime.Register("getInstance", "(Ljava/lang/String;Ljava/lang/String;)Ljavax/crypto/Cipher;", "")]
public static Javax.Crypto.Cipher GetInstance (string transformation, string provider);
static member GetInstance : string * string -> Javax.Crypto.Cipher

Parameters

transformation
String String

the name of the transformation to create a cipher for.

provider
String String

the name of the provider to ask for the transformation.

Returns

Exceptions

if the specified provider can not provide the transformation, or it is null, empty or in an invalid format.

if no provider with the specified name can be found.

if the requested padding scheme in the transformation is not available.

if the specified provider is null.

Remarks

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