Ejemplo n.º 1
0
 private static IEnumerable<SszElement> GetValues(Crosslink item)
 {
     yield return item.Shard.ToSszBasicElement();
     yield return item.ParentRoot.ToSszBasicVector();
     // Crosslinking data
     yield return item.StartEpoch.ToSszBasicElement();
     yield return item.EndEpoch.ToSszBasicElement();
     yield return item.DataRoot.ToSszBasicVector();
 }
Ejemplo n.º 2
0
 protected bool Equals(Crosslink other)
 {
     return(Name == other.Name && Positions.Equals(other.Positions));
 }
Ejemplo n.º 3
0
 public static SszContainer ToSszContainer(this Crosslink item)
 {
     return new SszContainer(GetValues(item));
 }
Ejemplo n.º 4
0
 public static Hash32 HashTreeRoot(this Crosslink item)
 {
     var tree = new SszTree(item.ToSszContainer());
     return new Hash32(tree.HashTreeRoot());
 }