| | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 2 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 3 | | // license information. |
| | 4 | |
|
| | 5 | | using System; |
| | 6 | |
|
| | 7 | | namespace Microsoft.Azure.KeyVault.Cryptography |
| | 8 | | { |
| | 9 | | /// <summary> |
| | 10 | | /// Abstract Algorithm. |
| | 11 | | /// </summary> |
| | 12 | | public abstract class Algorithm |
| | 13 | | { |
| | 14 | | private readonly string _name; |
| | 15 | |
|
| 58 | 16 | | protected Algorithm( string name ) |
| | 17 | | { |
| 58 | 18 | | if ( string.IsNullOrEmpty( name ) ) |
| 0 | 19 | | throw new ArgumentNullException( "name" ); |
| | 20 | |
|
| 58 | 21 | | _name = name; |
| 58 | 22 | | } |
| | 23 | |
|
| | 24 | | /// <summary> |
| | 25 | | /// The name of the algorithm |
| | 26 | | /// </summary> |
| | 27 | | public string Name |
| | 28 | | { |
| 12 | 29 | | get { return _name; } |
| | 30 | | } |
| | 31 | | } |
| | 32 | | } |