forked from microsoft/referencesource
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLocalizedEntryCollection.cs
More file actions
25 lines (24 loc) · 1 KB
/
Copy pathLocalizedEntryCollection.cs
File metadata and controls
25 lines (24 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
//------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//------------------------------------------------------------
using System.Collections.ObjectModel;
using System.Globalization;
namespace System.IdentityModel.Metadata
{
/// <summary>
/// A collection of <see cref="LocalizedEntry"/> objects.
/// </summary>
/// <typeparam name="T">The <see cref="LocalizedEntry"/> type.</typeparam>
public class LocalizedEntryCollection<T> : KeyedCollection<CultureInfo, T> where T : LocalizedEntry
{
/// <summary>
/// Gets the key for the <paramref name="item"/>.
/// </summary>
/// <param name="item">The input item for which the key is to be retrieved.</param>
/// <returns>A <see cref="CultureInfo"/> object representing the key for the <paramref name="item"/>.</returns>
protected override CultureInfo GetKeyForItem(T item)
{
return item.Language;
}
}
}