internal abstract SourceTree WithRootCore(SourceNode root);
protected abstract bool TryGetRootCore(out SourceNode root);
public bool TryGetRoot(out SourceNode root) { return(TryGetRootCore(out root)); }
public static NodeList <TNode> ToNodeList <TNode, TCore>(this ImmutableArray <TCore> cores, SourceNode parent = null) where TNode : SourceNode, INodeWithCore <TCore> where TCore : ICore <TNode> { var container = LazyNodeList <TNode, TCore> .CreateContainer(cores, parent); return(container.ToNodeList()); }
protected SourceNode(SourceNode parent) { Parent = parent; Tree = parent?.Tree; }
private LazyNodeList(ImmutableArray <TCore> cores, SourceNode parent) { Parent = parent; Cores = cores; Nodes = new ArrayElement <TNode> [Cores.Length]; }