diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2022-06-28 20:49:58 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2022-06-28 20:49:58 +0700 |
commit | dc5029c8650432ae04df78d2ead06a8349176b74 (patch) | |
tree | 306f232f9cf53762ccb427225dee958313b884fd /crypto/src/tls/ServerNameList.cs | |
parent | Generics migration in Ocsp, OpenPgp (diff) | |
download | BouncyCastle.NET-ed25519-dc5029c8650432ae04df78d2ead06a8349176b74.tar.xz |
Generics migration in Tls
Diffstat (limited to 'crypto/src/tls/ServerNameList.cs')
-rw-r--r-- | crypto/src/tls/ServerNameList.cs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crypto/src/tls/ServerNameList.cs b/crypto/src/tls/ServerNameList.cs index 915e94390..358e82a67 100644 --- a/crypto/src/tls/ServerNameList.cs +++ b/crypto/src/tls/ServerNameList.cs @@ -1,5 +1,5 @@ using System; -using System.Collections; +using System.Collections.Generic; using System.IO; using Org.BouncyCastle.Utilities; @@ -9,10 +9,10 @@ namespace Org.BouncyCastle.Tls { public sealed class ServerNameList { - private readonly IList m_serverNameList; + private readonly IList<ServerName> m_serverNameList; /// <param name="serverNameList">an <see cref="IList"/> of <see cref="ServerName"/>.</param> - public ServerNameList(IList serverNameList) + public ServerNameList(IList<ServerName> serverNameList) { if (null == serverNameList) throw new ArgumentNullException("serverNameList"); @@ -21,7 +21,7 @@ namespace Org.BouncyCastle.Tls } /// <returns>an <see cref="IList"/> of <see cref="ServerName"/>.</returns> - public IList ServerNames + public IList<ServerName> ServerNames { get { return m_serverNameList; } } @@ -60,7 +60,7 @@ namespace Org.BouncyCastle.Tls MemoryStream buf = new MemoryStream(data, false); short[] nameTypesSeen = TlsUtilities.EmptyShorts; - IList server_name_list = Platform.CreateArrayList(); + var server_name_list = new List<ServerName>(); while (buf.Position < buf.Length) { ServerName entry = ServerName.Parse(buf); |