PageRenderTime 47ms CodeModel.GetById 21ms RepoModel.GetById 0ms app.codeStats 0ms

/Highchart/Highchart.UI/Core/PlotOptions/PlotOptionsBar.cs

#
C# | 36 lines | 32 code | 4 blank | 0 comment | 1 complexity | 93539bf509f9229eac33704bd1ad95b4 MD5 | raw file
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using Newtonsoft.Json;
  6. namespace Highchart.Core.PlotOptions
  7. {
  8. [Serializable]
  9. public class PlotOptionsBar : PlotOptionsSeries
  10. {
  11. public string borderColor { get; set; }
  12. public int? borderRadius { get; set; }
  13. public int? borderWidth { get; set; }
  14. public bool? colorByPoint { get; set; }
  15. public int? groupPadding { get; set; }
  16. public int? minPointLength { get; set; }
  17. public int? pointPadding { get; set; }
  18. public int? pointWidth { get; set; }
  19. public override string ToString()
  20. {
  21. string ignored = JsonConvert.SerializeObject(this, Formatting.None, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore, DefaultValueHandling = DefaultValueHandling.Ignore });
  22. if (!string.IsNullOrEmpty(ignored))
  23. {
  24. return string.Format("plotOptions: {{ series: {0} }},", ignored);
  25. }
  26. else
  27. {
  28. return string.Empty;
  29. }
  30. }
  31. }
  32. }