Beispiel #1
0
 public static void AddChild(this ICompoundTerm term, Node newChild)
 {
     if (newChild == null)
     {
         throw new ArgumentNullException("newChild");
     }
     term.Children.Add(newChild);
 }
Beispiel #2
0
        private static string TermString(ICompoundTerm term)
        {
            const string typeName = "TODO"; // use reflection to get type name

            return(typeName +
                   " { " +
                   string.Join("", term.Children.Select(x => x.ToString())) +
                   " }");
        }