IChartItem.cs 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. using System;
  2. using CB.Entity;
  3. namespace CB.Interface
  4. {
  5. /// <summary>
  6. /// 走势图项接口
  7. /// </summary>
  8. /// <typeparam name="TEntity">彩种开奖数据</typeparam>
  9. /// <typeparam name="T">项对应的值或项的索引号</typeparam>
  10. public interface IChartItem<TEntity> where TEntity : LotteryOpenCode
  11. {
  12. /// <summary>
  13. /// 初始化项
  14. /// </summary>
  15. /// <param name="fomartString">fomart格式</param>
  16. /// <param name="chartItemConfig">项配置信息</param>
  17. /// <param name="entity">开奖数据</param>
  18. void Init(ChartCssConfigInfo cssConfig, TrendChartItemInfo itemConfig);
  19. /// <summary>
  20. /// 遗漏相关数据初使化
  21. /// </summary>
  22. /// <param name="TrendChartCofig">上期遗漏数据</param>
  23. /// <param name="i">对应计算项</param>
  24. void MissDataInit(TrendChartData TrendChartCofig, int i);
  25. /// <summary>
  26. /// 字符串返回遗漏数据(逗号分隔数组)
  27. /// </summary>
  28. /// <param name="missDataType">遗漏数据类型</param>
  29. /// <returns></returns>
  30. string GetMissData(MissDataType missDataType);
  31. /// <summary>
  32. /// 根据彩种开奖数据计算当前项的值(可以是配置项的数组索引号)
  33. /// </summary>
  34. /// <param name="entity"></param>
  35. /// <returns></returns>
  36. bool SetItemValue(TEntity entity);
  37. bool SetItemValue(TEntity entity, TEntity nextentity);
  38. /// <summary>
  39. /// 返回格式化字符串
  40. /// </summary>
  41. /// <param name="fomart">Fomart格式</param>
  42. /// <param name="cssConfig">CSS配置</param>
  43. /// <returns></returns>
  44. string GetFomartString(string fomart, ChartCssConfigInfo cssConfig = null);
  45. }
  46. }