Ejemplo n.º 1
0
 public void AddChild(ChoiceInfo child)
 {
     if (Children == null)
     {
         Children = new List <ChoiceInfo>();
     }
     Children.Add(child);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Creates a new instance of <see cref="Document"/>.
 /// </summary>
 /// <param name="name">Pair name.</param>
 /// <param name="assignment">Pair assignment.</param>
 /// <param name="value">Pair value.</param>
 /// <param name="nameInterval">Name <see cref="Interval"/>.</param>
 /// <param name="valueInterval">Value <see cref="Interval"/>.</param>
 /// <param name="assignmentInterval">Assignment <see cref="Interval"/>.</param>
 /// <param name="nameQuotesType">Name quotes type.</param>
 /// <param name="valueQuotesType">Value quotes type.</param>
 /// <param name="valueType">Type of value.</param>
 /// <param name="interpolationItems">List of interpolation objects.</param>
 /// <param name="valueIndent">Indent of value in the source code.</param>
 public Document(string name           = null, AssignmentEnum assignment = AssignmentEnum.None, string value = null,
                 Interval nameInterval = null, Interval valueInterval    = null, Interval assignmentInterval = null,
                 int nameQuotesType    = 0, int valueQuotesType          = 0, ValueType valueType = ValueType.None, List <object> interpolationItems = null,
                 int valueIndent       = 0) : base(name, assignment, value)
 {
     ValueInterval      = valueInterval;
     AssignmentInterval = assignmentInterval;
     NameInterval       = nameInterval;
     NameQuotesType     = nameQuotesType;
     ValueQuotesType    = valueQuotesType;
     ValueType          = valueType;
     InterpolationItems = interpolationItems;
     ValueIndent        = valueIndent;
     ChoiceInfo         = new ChoiceInfo(null, this);
 }
Ejemplo n.º 3
0
 public ChoiceInfo(ChoiceInfo parent, Pair choiceNode)
 {
     Parent     = parent;
     ChoiceNode = choiceNode;
 }
Ejemplo n.º 4
0
 public Document()
 {
     ChoiceInfo = new ChoiceInfo(null, this);
 }