Files
UptimeSharp/UptimeSharp.OldClassLib/Models/Response/RetrieveResponse.cs
T

38 lines
833 B
C#
Raw Normal View History

using System.Collections.Generic;
using System.Runtime.Serialization;
namespace UptimeSharp.Models
{
/// <summary>
/// Monitor Response
/// </summary>
[DataContract]
internal class RetrieveResponse : ResponseBase
{
/// <summary>
/// Gets or sets the item dictionary.
/// The list is 2 layers deep, so this one is necessary :-/
/// </summary>
/// <value>
/// The item dictionary.
/// </value>
[DataMember(Name = "monitors")]
public Dictionary<string, List<Monitor>> ItemDictionary { get; set; }
/// <summary>
/// Gets the items.
/// </summary>
/// <value>
/// The items.
/// </value>
[IgnoreDataMember]
public List<Monitor> Items
{
2013-08-18 14:26:01 +02:00
get
{
return ItemDictionary != null ? ItemDictionary["monitor"] : null;
}
}
}
}