| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131 | 
							- using System;
 
- using System.Collections.Generic;
 
- using System.Linq;
 
- using System.Text;
 
- using SCC.Models;
 
- namespace SCC.Crawler.DT
 
- {
 
-     
 
-     
 
-     
 
-     public class SingleValueFunction
 
-     {
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号码展示项", ChartItemType.SingleCell_OpenCodeItem, ChartItemClassName.SingleValue)]
 
-         public static string GetOpenCodeItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string num = "";
 
-             foreach (int item in list)
 
-             {
 
-                 num = num + item.ToString();
 
-             }
 
-             return num;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号和值项", ChartItemType.SingleCell_SumItem, ChartItemClassName.SingleValue)]
 
-         public static string GetSumItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSum(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号和值尾数项", ChartItemType.SingleCell_HeWeiItem, ChartItemClassName.SingleValue)]
 
-         public static string GetHeWeiItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return (LotteryUtils.GetSum(list) % 10).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号012比例项", ChartItemType.SingleCell_ProportionOf012Item, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOf012ItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetProportionOf012(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号质合项", ChartItemType.SingleCell_ZhiHeStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZhiHeItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (LotteryUtils.IsPrimeNumbers(item) ? "质" : "合");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号大小比例项", ChartItemType.SingleCell_ProportionOfDxItem, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOfDxItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetProportionOfDX(list, splitNumber);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号奇偶比列项", ChartItemType.SingleCell_ProportionOfJoItem, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOfJoItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetProportionOfJO(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号质合比列项", ChartItemType.SingleCell_ProportionOfZhItem, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOfZhItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetProportionOfZh(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号跨度项(大于两个号码)", ChartItemType.SingleCell_SpanItem, ChartItemClassName.SingleValue)]
 
-         public static string GetSpanItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSpan(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号组三跨度项(大于两个号码)", ChartItemType.SingleCell_ZSSpanItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZSSpanItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSpan(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号AC值计算出012路值", ChartItemType.SingleCell_Ac012Lu, ChartItemClassName.SingleValue)]
 
-         public static string GetAc012Lu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string[] kjh = new string[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 kjh[i] = list[i].ToString();
 
-             }
 
-             string ac = LotteryUtils.GetAC(kjh).ToString();
 
-             return (int.Parse(ac) % 3).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号AC值计算出质合值", ChartItemType.SingleCell_AcZhiHe, ChartItemClassName.SingleValue)]
 
-         public static string GetAcZhiHe<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string[] kjh = new string[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 kjh[i] = list[i].ToString();
 
-             }
 
-             string ac = LotteryUtils.GetAC(kjh).ToString();
 
-             if (LotteryUtils.IsPrimeNumbers(int.Parse(ac)))
 
-             {
 
-                 return "质";
 
-             }
 
-             else
 
-             {
 
-                 return "合";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]期号项", ChartItemType.Term_TermItem, ChartItemClassName.SingleValue)]
 
-         public static string GetTermItemValue<TEntity>(TEntity entity) where TEntity : LotteryOpenCode
 
-         {
 
-             return entity.Term.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]大乐透附加区值", ChartItemType.SingleCell_HqItem, ChartItemClassName.SingleValue)]
 
-         public static string GetHqValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 tag += list[i].ToString("00");
 
-                 if (i != list.Count - 1)
 
-                 {
 
-                     tag += ",";
 
-                 }
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号计算AC值", ChartItemType.SingleCell_Ac, ChartItemClassName.SingleValue)]
 
-         public static string GetAcValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string[] kjh = new string[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 kjh[i] = list[i].ToString();
 
-             }
 
-             return LotteryUtils.GetAC(kjh).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]单个开奖号码分布项", ChartItemType.SingleValue_QuJianFenBu, ChartItemClassName.SingleValue)]
 
-         public static string GetQuJianStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             return (entity.OpenCode[indexStart]).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和尾奇偶分布项", ChartItemType.SingleValue_HeWeiJiOu, ChartItemClassName.SingleValue)]
 
-         public static string GetHeWeiJiOuFenBu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int a = LotteryUtils.GetSum(list) % 10;
 
-             if (a % 2 == 0)
 
-             {
 
-                 return "偶";
 
-             }
 
-             else
 
-             {
 
-                 return "奇";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号码单个数字项", ChartItemType.SingleValue_NumberItem, ChartItemClassName.SingleValue)]
 
-         public static string GetNumberItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             return entity.OpenCode[indexStart].ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号重号项", ChartItemType.SingleCell_RepeatedNumber, ChartItemClassName.SingleValue)]
 
-         public static string GetRepeatNumItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int minValue, int maxValue, ref int[] lastItemIndex, int itemcout) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             if (null == lastItemIndex)
 
-             {
 
-                 lastItemIndex = new int[list.Count];
 
-                 for (int i = 0; i < list.Count; i++)
 
-                 {
 
-                     lastItemIndex[i] = list[i];
 
-                 }
 
-                 return "0";
 
-             }
 
-             int count = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (lastItemIndex.Contains(item))
 
-                 {
 
-                     count++;
 
-                 }
 
-             }
 
-             lastItemIndex = new int[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 lastItemIndex[i] = list[i];
 
-             }
 
-             return count.ToString();
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-             
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号连号项", ChartItemType.SingleCell_LinkNumber, ChartItemClassName.SingleValue)]
 
-         public static string GetLinkNumItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             int LinkNum = 0;
 
-             List<int> nums = entity.OpenCode.Take(indexEnd - indexStart).ToList();
 
-             nums.Sort();
 
-             for (int i = 1; i < nums.Count; i++)
 
-             {
 
-                 if (i != 0 && nums[i - 1] + 1 == nums[i])
 
-                 {
 
-                     LinkNum++;
 
-                 }
 
-             }
 
-             return LinkNum.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]试机号和值项", ChartItemType.SingleCell_ShiJiHaoHzItem, ChartItemClassName.SingleValue)]
 
-         public static string GetShiJiHaoHzValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             return LotteryUtils.GetSum(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]试机号跨度项", ChartItemType.SingleCell_ShiJiHaoSpanItem, ChartItemClassName.SingleValue)]
 
-         public static string GetShiJiHaoSpanValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             return LotteryUtils.GetSpan(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]试机号奇偶比例项", ChartItemType.SingleCell_ProportionOfShiJiHaoJoItem, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOfShiJiHaoJoItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             return LotteryUtils.GetProportionOfJO(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]试机号大小比例项", ChartItemType.SingleCell_ProportionOfShiJiHaoDxItem, ChartItemClassName.SingleValue)]
 
-         public static string GetProportionOfShiJiHaoDxItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             return LotteryUtils.GetProportionOfDX(list, splitNumber);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号组三遗漏项", ChartItemType.SingleCell_ZsMissItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZsMissItem<TEntity>(TEntity entity, ref long lastTerm) where TEntity : LotteryOpenCode
 
-         {
 
-             string miss = "";
 
-             if (lastTerm == 0)
 
-             {
 
-                 lastTerm = entity.Term;
 
-                 return "0";
 
-             }
 
-             if (entity.Term.ToString().Substring(0, 4) == lastTerm.ToString().Substring(0, 4))
 
-             {
 
-                 miss = (entity.Term - lastTerm - 1).ToString();
 
-                 lastTerm = entity.Term;
 
-                 return miss;
 
-             }
 
-             
 
-             int year = Convert.ToInt32(lastTerm.ToString().Substring(0, 4));
 
-             
 
-             long lastmaxqi = 0;
 
-             if ((year % 4 == 0 && year % 100 != 0) || year % 400 == 0)
 
-             {
 
-                 
 
-                 lastmaxqi = year * 1000 + 359;
 
-             }
 
-             else
 
-             {
 
-                 lastmaxqi = year * 1000 + 358;
 
-             }
 
-             long num = lastmaxqi - lastTerm - 1;
 
-             long Tnum = num + (entity.Term - (Convert.ToInt32(entity.Term.ToString().Substring(0, 4)) * 1000 + 1));
 
-             lastTerm = entity.Term;
 
-             return Tnum.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号组三号码项", ChartItemType.SingleCell_ZsHaoMaItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZsHaoMaValue<TEntity>(TEntity entity) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (list[0] == list[1])
 
-             {
 
-                 return list[0].ToString();
 
-             }
 
-             if (list[0] == list[2])
 
-             {
 
-                 return list[0].ToString();
 
-             }
 
-             return list[1].ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]试机号展示项(限福彩3D和排列三)", ChartItemType.SingleCell_ShiJiHao, ChartItemClassName.SingleValue)]
 
-         public static string GetShiJiHaoItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             string num = "";
 
-             foreach (int item in list)
 
-             {
 
-                 num = num + item.ToString();
 
-             }
 
-             return num;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号三区比项(限双色球)", ChartItemType.SingleCell_SanQu, ChartItemClassName.SingleValue)]
 
-         public static string GetSsqsanqu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.SsqSanQu(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]开奖号码012值", ChartItemType.SingleCell_012StatusItem, ChartItemClassName.SingleValue)]
 
-         public static string Get012StatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (item % 3).ToString();
 
-             }
 
-             return tag;
 
-         }
 
-         [ChartFunction("[单值多列]开奖号跨度项(两个号码)", ChartItemType.SingleValue_SpanNumberItem, ChartItemClassName.SingleValue)]
 
-         public static string GetSpanNumberItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             return (Math.Abs(entity.OpenCode[indexStart] - entity.OpenCode[indexEnd])).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号跨度(大于两个号码)分布项", ChartItemType.SingleValue_SpanItem, ChartItemClassName.SingleValue)]
 
-         public static string GetSpanSingleValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSpan(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和尾分布项", ChartItemType.SingleValue_HeWeiItem, ChartItemClassName.SingleValue)]
 
-         public static string GetHeWeiSingleValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return (LotteryUtils.GetSum(list) % 10).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和值分布项", ChartItemType.SingleValue_SumItem, ChartItemClassName.SingleValue)]
 
-         public static string GetSumSingleValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSum(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和值分布项(根据区间)", ChartItemType.SingleValue_SumItemGroup, ChartItemClassName.SingleValue)]
 
-         public static string GetSumSingleValueGroup<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.GetSum(list).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号AC值计算出奇偶分布项", ChartItemType.SingleCell_AcJiOu, ChartItemClassName.SingleValue)]
 
-         public static string GetAcJiOu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string[] kjh = new string[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 kjh[i] = list[i].ToString();
 
-             }
 
-             string ac = LotteryUtils.GetAC(kjh).ToString();
 
-             if (LotteryUtils.IsJoNumbers(int.Parse(ac)))
 
-             {
 
-                 return "奇";
 
-             }
 
-             else
 
-             {
 
-                 return "偶";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号码大小分布项", ChartItemType.SingleValue_DaXiaoStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetDaXiaoStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (item >= splitNumber ? "大" : "小");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号码奇偶分布项", ChartItemType.SingleValue_JiOuStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetJiOuStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (1 == item % 2 ? "奇" : "偶");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号码012路分布项", ChartItemType.SingleValue_Number012StatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetNumber012StatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (item % 3).ToString();
 
-             }
 
-             return tag;
 
-             
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号质合分布项", ChartItemType.SingleValue_ZhiHeStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZhiHeStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (LotteryUtils.IsPrimeNumbers(item) ? "质" : "合");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号组合项(组三、组六、豹子:限三个号码)", ChartItemType.SingleValue_ZuHeStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZuHeStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = LotteryUtils.GetOpenCodeList(entity, indexStart, indexEnd);
 
-             IDictionary<int, int> d = new Dictionary<int, int>();
 
-             foreach (var item in list)
 
-             {
 
-                 if (!d.ContainsKey(item))
 
-                     d.Add(item, 0);
 
-                 d[item]++;
 
-             }
 
-             var tag = "组六";
 
-             foreach (var item in d.Keys)
 
-             {
 
-                 if (3 == d[item])
 
-                 {
 
-                     tag = 2 == count ? "组三" : "豹子";
 
-                     break;
 
-                 }
 
-                 if (2 == d[item])
 
-                 {
 
-                     tag = "组三";
 
-                     break;
 
-                 }
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]试机号展示项(限定福彩3D和排列三)", ChartItemType.SingleValue_ShiJiHao, ChartItemClassName.SingleValue)]
 
-         public static string GetShiJiHaoSingleValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             string num = "";
 
-             foreach (int item in list)
 
-             {
 
-                 num = num + item.ToString();
 
-             }
 
-             return num;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和值的奇偶分布项", ChartItemType.SingleValue_HzJoStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetHzJoStatusValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int sum = LotteryUtils.GetSum(list);
 
-             if (sum % 2 == 0)
 
-             {
 
-                 return "偶";
 
-             }
 
-             else
 
-             {
 
-                 return "奇";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号和值大小分布项", ChartItemType.SingleValue_HzDxStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetHzDxStatusValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int SplitNumberOfDX, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int sum = LotteryUtils.GetSum(list);
 
-             if (sum >= SplitNumberOfDX)
 
-             {
 
-                 return "大";
 
-             }
 
-             else
 
-             {
 
-                 return "小";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号单个号码大小分布项", ChartItemType.SingleValue_DxStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetDxStatusValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (LotteryUtils.IsDxNumbers(item) ? "大" : "小");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号单个号码奇偶分布项", ChartItemType.SingleValue_JoStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetJoStatusItem<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (LotteryUtils.IsJoNumbers(item) ? "奇" : "偶");
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号组三分布项", ChartItemType.SingleValue_ZsStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZsStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (list[0] == list[1])
 
-             {
 
-                 return "AAB";
 
-             }
 
-             if (list[0] == list[2])
 
-             {
 
-                 return "ABA";
 
-             }
 
-             return "BAA";
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号组三奇偶分布项", ChartItemType.SingleValue_ZsJoStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZsJoStatusValue<TEntity>(TEntity entity) where TEntity : LotteryOpenCode
 
-         {
 
-             int num = Convert.ToInt32(GetZsHaoMaValue(entity));
 
-             if (num % 2 == 0)
 
-             {
 
-                 return "偶";
 
-             }
 
-             return "奇";
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号组三大小分布项", ChartItemType.SingleValue_ZsDxStatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZsDxStatusValue<TEntity>(TEntity entity, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             int num = Convert.ToInt32(GetZsHaoMaValue(entity));
 
-             if (num > splitNumber)
 
-             {
 
-                 return "大";
 
-             }
 
-             return "小";
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号组三012路分布项", ChartItemType.SingleValue_Zs012StatusItem, ChartItemClassName.SingleValue)]
 
-         public static string GetZs012StatusValue<TEntity>(TEntity entity) where TEntity : LotteryOpenCode
 
-         {
 
-             int num = Convert.ToInt32(GetZsHaoMaValue(entity));
 
-             return (num % 3).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]试机号类型项(组三、组六、豹子:限三个开奖号码)", ChartItemType.SingleValue_ShiJiHaoTypeItem, ChartItemClassName.SingleValue)]
 
-         public static string GetShiJiHaoTyepValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = GetShiJiHaoList<TEntity>(entity, indexStart, indexEnd);
 
-             IDictionary<int, int> d = new Dictionary<int, int>();
 
-             foreach (var item in list)
 
-             {
 
-                 if (!d.ContainsKey(item))
 
-                     d.Add(item, 0);
 
-                 d[item]++;
 
-             }
 
-             var tag = "组六";
 
-             foreach (var item in d.Keys)
 
-             {
 
-                 if (3 == d[item])
 
-                 {
 
-                     tag = 2 == count ? "组三" : "豹子";
 
-                     break;
 
-                 }
 
-                 if (2 == d[item])
 
-                 {
 
-                     tag = "组三";
 
-                     break;
 
-                 }
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号生肖分布项", ChartItemType.SingleValue_SX, ChartItemClassName.SingleValue)]
 
-         public static string GetSXStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string[] SX = new string[12] { "鼠", "牛", "虎", "兔", "龙", "蛇", "马", "羊", "猴", "鸡", "狗", "猪" };
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 tag = tag + (item % 12 == 0 ? "猪" : SX[item % 12 - 1]);
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号季节分布项", ChartItemType.SingleValue_JJ, ChartItemClassName.SingleValue)]
 
-         public static string GetJJStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 if (item >= 1 && item <= 9)
 
-                 {
 
-                     tag = tag + "春";
 
-                     continue;
 
-                 }
 
-                 if (item >= 10 && item <= 18)
 
-                 {
 
-                     tag = tag + "夏";
 
-                     continue;
 
-                 }
 
-                 if (item >= 19 && item <= 27)
 
-                 {
 
-                     tag = tag + "秋";
 
-                     continue;
 
-                 }
 
-                 if (item >= 28 && item <= 36)
 
-                 {
 
-                     tag = tag + "冬";
 
-                     continue;
 
-                 }
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]开奖号方位分布项", ChartItemType.SingleValue_FW, ChartItemClassName.SingleValue)]
 
-         public static string GetFWStatusItemValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             var tag = "";
 
-             foreach (var item in list)
 
-             {
 
-                 if (item >= 1 && item <= 18)
 
-                 {
 
-                     if (item % 2 == 1)
 
-                     {
 
-                         tag = tag + "东";
 
-                     }
 
-                     else
 
-                     {
 
-                         tag = tag + "南";
 
-                     }
 
-                     continue;
 
-                 }
 
-                 if (item >= 19 && item <= 36)
 
-                 {
 
-                     if (item % 2 == 1)
 
-                     {
 
-                         tag = tag + "西";
 
-                     }
 
-                     else
 
-                     {
 
-                         tag = tag + "北";
 
-                     }
 
-                     continue;
 
-                 }
 
-             }
 
-             return tag;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         private static IList<int> GetShiJiHaoList<TEntity>(TEntity entity, int indexStart, int indexEnd) where TEntity : LotteryOpenCode
 
-         {
 
-             if (entity.ShiJiHao == "-1")
 
-             {
 
-                 return new List<int> { -1, -1, -1 };
 
-             }
 
-             string[] arr_sjh = entity.ShiJiHao.Split(',');
 
-             IList<int> list = new List<int>();
 
-             foreach (var item in arr_sjh)
 
-             {
 
-                 list.Add(Convert.ToInt32(item));
 
-             }
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return list;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]回摆", ChartItemType.SingleValue_HB, ChartItemClassName.SingleValue)]
 
-         public static string HBSingleValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int minValue, int maxValue, ref int[] lastItemIndex, int itemcout) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             if (null == lastItemIndex)
 
-             {
 
-                 lastItemIndex = new int[list.Count];
 
-                 for (int i = 0; i < list.Count; i++)
 
-                 {
 
-                     lastItemIndex[i] = list[i];
 
-                 }
 
-                 return "重号";
 
-             }
 
-             string result = "";
 
-             foreach (var item in list)
 
-             {
 
-                 if (lastItemIndex[0] > item)
 
-                 {
 
-                     result = "反向";
 
-                     break;
 
-                 }
 
-             }
 
-             foreach (var item in list)
 
-             {
 
-                 if (lastItemIndex[0] < item)
 
-                 {
 
-                     result = "正向";
 
-                     break;
 
-                 }
 
-             }
 
-             foreach (var item in list)
 
-             {
 
-                 if (lastItemIndex[0] == item)
 
-                 {
 
-                     result = "重号";
 
-                     break;
 
-                 }
 
-             }
 
-             lastItemIndex = new int[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 lastItemIndex[i] = list[i];
 
-             }
 
-             return result;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]振幅", ChartItemType.SingleCell_ZF, ChartItemClassName.SingleValue)]
 
-         public static string ZFSingleCell<TEntity>(TEntity entity, int indexStart, int indexEnd, int minValue, int maxValue, ref int[] lastItemIndex, int itemcout) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             if (null == lastItemIndex)
 
-             {
 
-                 lastItemIndex = new int[list.Count];
 
-                 for (int i = 0; i < list.Count; i++)
 
-                 {
 
-                     lastItemIndex[i] = list[i];
 
-                 }
 
-                 return list.Sum().ToString();
 
-             }
 
-             int result = list.Sum() - lastItemIndex.Sum();
 
-             lastItemIndex = new int[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 lastItemIndex[i] = list[i];
 
-             }
 
-             return Math.Abs(result).ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]福建31选7三区比", ChartItemType.SingleCell_FJ31X7SanQu, ChartItemClassName.SingleValue)]
 
-         public static string GetFj31x7sanqu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.Fj31x7SanQu(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]福建36选7三区比", ChartItemType.SingleCell_FJ36X7SanQu, ChartItemClassName.SingleValue)]
 
-         public static string GetFj36x7sanqu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.Fj36x7SanQu(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]和尾大小", ChartItemType.SingleValue_HeWeiDx, ChartItemClassName.SingleValue)]
 
-         public static string GetHeWeiDxFenBu<TEntity>(TEntity entity, int indexStart, int indexEnd, int SplitNumberOfDX, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int sum = LotteryUtils.GetSum(list);
 
-             int hw = sum % 10;
 
-             if (hw >= SplitNumberOfDX)
 
-             {
 
-                 return "大";
 
-             }
 
-             else
 
-             {
 
-                 return "小";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]东方6+1生肖", ChartItemType.SingleValue_ShengXiao, ChartItemClassName.SingleValue)]
 
-         public static string Getdf6j1sx<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             switch (list[0])
 
-             {
 
-                 case 1:
 
-                     return "鼠";
 
-                 case 2:
 
-                     return "牛";
 
-                 case 3:
 
-                     return "虎";
 
-                 case 4:
 
-                     return "兔";
 
-                 case 5:
 
-                     return "龙";
 
-                 case 6:
 
-                     return "蛇";
 
-                 case 7:
 
-                     return "马";
 
-                 case 8:
 
-                     return "羊";
 
-                 case 9:
 
-                     return "猴";
 
-                 case 10:
 
-                     return "鸡";
 
-                 case 11:
 
-                     return "狗";
 
-                 case 12:
 
-                     return "猪";
 
-                 default:
 
-                     return "";
 
-             }
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]华东15选5三区比", ChartItemType.SingleCell_Hd15x5SanQU, ChartItemClassName.SingleValue)]
 
-         public static string Gethd15x5sanqu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.Hd15x5SanQu(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]华东15选5一区的个数", ChartItemType.SingleValue_Hd11x5Yq, ChartItemClassName.SingleValue)]
 
-         public static string Gethd15x5Yq<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int min, int max) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int num = 0;
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 if (list[i] >= min && list[i] <= max)
 
-                 {
 
-                     num++;
 
-                 }
 
-             }
 
-             return num.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]华东15选5二区的个数", ChartItemType.SingleValue_Hd11x5Eq, ChartItemClassName.SingleValue)]
 
-         public static string Gethd15x5Eq<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int min, int max) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int num = 0;
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 if (list[i] >= min && list[i] <= max)
 
-                 {
 
-                     num++;
 
-                 }
 
-             }
 
-             return num.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]华东15选5三区的个数", ChartItemType.SingleValue_Hd11x5Sq, ChartItemClassName.SingleValue)]
 
-         public static string Gethd15x5Sq<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int min, int max) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int num = 0;
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 if (list[i] >= min && list[i] <= max)
 
-                 {
 
-                     num++;
 
-                 }
 
-             }
 
-             return num.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值单列]南粤36选7三区比", ChartItemType.SingleCell_NY36x7Sanqu, ChartItemClassName.SingleValue)]
 
-         public static string Getny36x7sanqu<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             return LotteryUtils.Ny36x7SanQu(list);
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]和值012路", ChartItemType.SingleCell_Hz012, ChartItemClassName.SingleValue)]
 
-         public static string GetHz012Value<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string hz = (list.Sum() % 3).ToString();
 
-             return hz;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]快3三不同走势", ChartItemType.SingleValue_K3sbt, ChartItemClassName.SingleValue)]
 
-         public static string GetK3sbtValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, string[] ItemString) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int[] k3s = new int[list.Count];
 
-             for (int i = 0; i < list.Count; i++)
 
-             {
 
-                 k3s[i] = list[i];
 
-             }
 
-             Array.Sort(k3s);
 
-             string result = "";
 
-             for (int i = 0; i < k3s.Count(); i++)
 
-             {
 
-                 result += k3s[i];
 
-             }
 
-             if (ItemString.Contains(result))
 
-             {
 
-                 return result;
 
-             }
 
-             return "";
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]快3二不同(单值)", ChartItemType.SingleCell_K3ebt, ChartItemClassName.SingleValue)]
 
-         public static string GetEbtValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string result = "";
 
-             if (list.Count != 3)
 
-             {
 
-                 return result;
 
-             }
 
-             if (list[0] == list[1])
 
-             {
 
-                 result = list[0].ToString() + list[1].ToString();
 
-                 return result;
 
-             }
 
-             if (list[0] == list[2])
 
-             {
 
-                 result = list[0].ToString() + list[2].ToString();
 
-                 return result;
 
-             }
 
-             if (list[1] == list[2])
 
-             {
 
-                 result = list[1].ToString() + list[2].ToString();
 
-                 return result;
 
-             }
 
-             return result;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]奇偶个数", ChartItemType.SingleValue_JoValue, ChartItemClassName.SingleValue)]
 
-         public static string GetJoValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (item % 2 != 0)
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]大小个数", ChartItemType.SingleValue_DxValue, ChartItemClassName.SingleValue)]
 
-         public static string GetDxValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (item >= splitNumber)
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]质合个数", ChartItemType.SingleValue_ZhValue, ChartItemClassName.SingleValue)]
 
-         public static string GetZhValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int[] zs = { 1, 2, 3, 5 };
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (zs.Contains(item))
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]大小奇偶", ChartItemType.SingleValue_DxjoValue, ChartItemClassName.SingleValue)]
 
-         public static string GetDxjoValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int splitNumber, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             string result = "";
 
-             if (list[0] > splitNumber)
 
-             {
 
-                 result = "大";
 
-             }
 
-             else
 
-             {
 
-                 result = "小";
 
-             }
 
-             if (list[0] % 2 == 0)
 
-             {
 
-                 result += "双";
 
-             }
 
-             else
 
-             {
 
-                 result += "单";
 
-             }
 
-             return result;
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]小数个数", ChartItemType.SingleValue_XsValue, ChartItemClassName.SingleValue)]
 
-         public static string GetXsValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count, int splitNumber) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (item < splitNumber)
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]合数个数", ChartItemType.SingleValue_HsValue, ChartItemClassName.SingleValue)]
 
-         public static string GetHsValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int[] zs = { 4, 6 };
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (zs.Contains(item))
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         
 
-         [ChartFunction("[单值多列]偶数个数", ChartItemType.SingleValue_OsValue, ChartItemClassName.SingleValue)]
 
-         public static string GetOsValue<TEntity>(TEntity entity, int indexStart, int indexEnd, int count) where TEntity : LotteryOpenCode
 
-         {
 
-             IList<int> list = new List<int>(entity.OpenCode);
 
-             if (-1 != indexEnd)
 
-             {
 
-                 for (int i = list.Count - 1; i >= indexEnd; i--)
 
-                 { list.RemoveAt(indexEnd); }
 
-             }
 
-             for (int i = 0; i < indexStart; i++)
 
-             { list.RemoveAt(0); }
 
-             int result = 0;
 
-             foreach (var item in list)
 
-             {
 
-                 if (item % 2 == 0)
 
-                 {
 
-                     result++;
 
-                 }
 
-             }
 
-             return result.ToString();
 
-         }
 
-     }
 
- }
 
 
  |