# < Summary

Information

Class: | Renci.SshNet.Security.Org.BouncyCastle.Crypto.AsymmetricCipherKeyPair
Assembly: | Renci.SshNet
File(s): | \home\appveyor\projects\ssh-net\src\Renci.SshNet\Security\BouncyCastle\crypto\AsymmetricCipherKeyPair.cs

Line coverage
84%

Covered lines: | 11
Uncovered lines: | 2
Coverable lines: | 13
Total lines: | 33
Line coverage: | 84.6%

Branch coverage
50%

Covered branches: | 2
Total branches: | 4
Branch coverage: | 50%

Method coverage

Feature is only available for sponsors

Upgrade to PRO version

# Metrics

Method | Branch coverage | Cyclomatic complexity | Line coverage
--- | --- | --- | ---
.ctor(...) | 50% | 4 | 81.81%
get_Public() | 100% | 1 | 100%
get_Private() | 100% | 1 | 100%

# File(s)

## \home\appveyor\projects\ssh-net\src\Renci.SshNet\Security\BouncyCastle\crypto\AsymmetricCipherKeyPair.cs

| # | Line |  | Line coverage
--- | --- | --- | --- | ---
|  | `1` |  | `using System;`
|  | `2` |  | ``
|  | `3` |  | `namespace Renci.SshNet.Security.Org.BouncyCastle.Crypto`
|  | `4` |  | `{`
|  | `5` |  | `internal class AsymmetricCipherKeyPair`
|  | `6` |  | `{`
|  | `7` |  | `private readonly AsymmetricKeyParameter publicParameter;`
|  | `8` |  | `private readonly AsymmetricKeyParameter privateParameter;`
|  | `9` |  | ``
| 9 | `10` |  | `public AsymmetricCipherKeyPair(`
| 9 | `11` |  | `AsymmetricKeyParameter publicParameter,`
| 9 | `12` |  | `AsymmetricKeyParameter privateParameter)`
| 9 | `13` |  | `{`
| 9 | `14` |  | `if (publicParameter.IsPrivate)`
| 0 | `15` |  | `throw new ArgumentException("Expected a public key", "publicParameter");`
| 9 | `16` |  | `if (!privateParameter.IsPrivate)`
| 0 | `17` |  | `throw new ArgumentException("Expected a private key", "privateParameter");`
|  | `18` |  | ``
| 9 | `19` |  | `this.publicParameter = publicParameter;`
| 9 | `20` |  | `this.privateParameter = privateParameter;`
| 9 | `21` |  | `}`
|  | `22` |  | ``
|  | `23` |  | `public AsymmetricKeyParameter Public`
|  | `24` |  | `{`
| 27 | `25` |  | `get { return publicParameter; }`
|  | `26` |  | `}`
|  | `27` |  | ``
|  | `28` |  | `public AsymmetricKeyParameter Private`
|  | `29` |  | `{`
| 27 | `30` |  | `get { return privateParameter; }`
|  | `31` |  | `}`
|  | `32` |  | `}`
|  | `33` |  | `}`

# Methods/Properties

.ctor(Renci.SshNet.Security.Org.BouncyCastle.Crypto.AsymmetricKeyParameter,Renci.SshNet.Security.Org.BouncyCastle.Crypto.AsymmetricKeyParameter)
get_Public()
get_Private()