コード例 #1
0
 public int SameFlags(BlockInfo other)
 {
     return(AllFlags.Intersect(other.AllFlags).Count());
 }
コード例 #2
0
 public int SameOtherFlags(BlockInfo other)
 {
     return(OtherFlags.Intersect(other.OtherFlags).Count());
 }
コード例 #3
0
 public IEnumerable <BlockInfo> SimilarTo(BlockInfo block)
 {
     return(BlockInfosList.Where(i => block != i).OrderByDescending(i => i.SameObviousFlags(block) * 100 + i.SameOtherFlags(block) * 10 + (i.Group == block.Group  ? 1 : 0)));
 }