Tempest.RSACrypto.ImportKey C# (CSharp) Method

ImportKey() public method

public ImportKey ( RSAAsymmetricKey key ) : void
key RSAAsymmetricKey
return void
        public void ImportKey(RSAAsymmetricKey key)
        {
            if (key == null)
                throw new ArgumentNullException ("key");

            var rsaKey = (key as RSAAsymmetricKey);
            if (rsaKey == null)
                throw new ArgumentException ("key must be RSAAsymmetricKey");

            this.rsaCrypto.ImportParameters (rsaKey);
        }