using System;
namespace Spectre.Console
{
///
/// An item that's shown in a breakdown chart.
///
public sealed class BreakdownChartItem : IBreakdownChartItem
{
///
/// Gets the item label.
///
public string Label { get; }
///
/// Gets the item value.
///
public double Value { get; }
///
/// Gets the item color.
///
public Color Color { get; }
///
/// Initializes a new instance of the class.
///
/// The item label.
/// The item value.
/// The item color.
public BreakdownChartItem(string label, double value, Color color)
{
Label = label ?? throw new ArgumentNullException(nameof(label));
Value = value;
Color = color;
}
}
}