public void Complete() { if (IsComplete) return; NodeType.CompletionAction(this); _SelfReference = this[Namespace.NamesPrefix + Namespace.MemberNames.NameofThis]; _NameNode = this[Namespace.NamesPrefix + Namespace.MemberNames.NameofName].AsTypeOrNull<IHdumName>(); IsComplete = true; }
protected BaseHdumNode(IHdumNode parent, IHdumType type, String name) { _Members = new OrderedDictionary<String, IHdumNode>(); _Children = new List<IHdumNode>(); _SelfReference = this; _Parent = parent; _Root = parent != null ? parent.Root : this; _NodeType = type; _Namespace = type.Namespace; var names = _Namespace.MemberNames; var prefix = _Namespace.NamesPrefix; this[prefix + names.NameofThis] = _SelfReference; this[prefix + names.NameofParent] = _Parent; this[prefix + names.NameofRoot] = _Root; this[prefix + names.NameofType] = _NodeType; _NameNode = name != null ? _Namespace.TypeofName.CreateNode(this, name).As<IHdumName>() : null; this[prefix + names.NameofName] = _NameNode; }