Exemple #1
0
 protected Builder(BlockId id)
 {
     _id           = id;
     _predecessors = ImmutableSortedSet.CreateBuilder <BlockId>();
     _successors   = ImmutableSortedSet.CreateBuilder <BlockId>();
 }
Exemple #2
0
 protected abstract Block ToBlock(
     BlockId id, ImmutableSortedSet <BlockId> predecssors, ImmutableSortedSet <BlockId> successors);
Exemple #3
0
 public TBlock GetBlock(BlockId id)
 => _idToBlockMap[id];
Exemple #4
0
            public void AddNode(BlockId id)
            {
                var blockBuilder = CreateBlockBuilder(id);

                _builders.Add(id, blockBuilder);
            }
Exemple #5
0
 public TBlockBuilder GetBlockBuilder(BlockId id)
 {
     return(_builders[id]);
 }
Exemple #6
0
 protected abstract TBlockBuilder CreateBlockBuilder(BlockId id);
Exemple #7
0
 protected Block(BlockId id, ImmutableSortedSet <BlockId> predecessors, ImmutableSortedSet <BlockId> successors)
 {
     this.ID           = id;
     this.Predecessors = predecessors;
     this.Successors   = successors;
 }