public static bool IsShown(this Racr.AstNode n) { return(n.AttValue <bool>("IsShown")); }
static Control Widget(this Ast n) { return(n.AttValue <Control>("Widget")); }
public static Racr.AstNode FindActive(this Racr.AstNode n, string name) { return(n.AttValue <Racr.AstNode>("FindActive", name)); }
public static bool IsLValid(this Racr.AstNode n) { return(n.AttValue <bool>("IsLValid")); }
public static string SExpr(this Racr.AstNode n) { return(n.AttValue <string>("SExpr")); }
public static Racr.AstNode ErrorQuestion(this Racr.AstNode n) { return(n.AttValue <Racr.AstNode>("ErrorQuestion")); }
public static bool IsErrorQuestion(this Ast n) { return(n.AttValue <bool>("IsErrorQuestion")); }
public static Control Widget(this Racr.AstNode n) { return(n.AttValue <Control>("Widget")); }
// Attribute Accessors: public static Ast Root(this Ast n) { return(n.AttValue <Ast>("Root")); }
public static Ast ErrorQuestion(this Ast n) { return(n.AttValue <Ast>("ErrorQuestion")); }
public static object Value(this Ast n) { return(n.AttValue <object>("Value")); }
public static Ast FindActive(this Ast n, string name) { return(n.AttValue <Ast>("FindActive", name)); }
public static bool IsShown(this Ast n) { return(n.AttValue <bool>("IsShown")); }
public static bool IsActive(this Ast n) { return(n.AttValue <bool>("IsActive")); }
public static Ast GLookup(this Ast n, string name) { return(n.AttValue <Ast>("GLookup", name)); }
public static object Value(this Racr.AstNode n) { return(n.AttValue <object>("Value")); }
static void TestFoo() { var spec = new MySpec(); var root = new Racr.AstNode(spec, "A", new Racr.AstList( new B(spec, "abc"), new B(spec, "123"), new B(spec, "xyz")), new Racr.AstNode(spec, "C"), "hiya"); root.ForEachChild((i, o) => { var node = o as Racr.AstNode; if (node != null) Console.WriteLine("{0}: {1}", i, node.NodeType()); else Console.WriteLine("{0}: {1}", i, o); }, new Racr.Range(2)); Console.WriteLine("---"); Console.WriteLine("M: {0}", root.M()); Console.WriteLine("N: {0}", root.N()); Console.WriteLine("a: {0}", root.AttValue("a")); Console.WriteLine("b: {0}", root.AttValue("b", 3)); Console.WriteLine("kids: {0}", root.AttValue("kids")); var index = root.GetList().Child(1).AttValue<int>("bar", 3); Console.WriteLine("index: {0}", index); Console.WriteLine("---"); var c = root.FindChild((i, o) => { return i == 2; }) as Racr.AstNode; Console.WriteLine("{0}", c.NodeType()); Console.WriteLine("---"); Console.WriteLine(root); Console.WriteLine("NodeType: {0}", root.NodeType()); Console.WriteLine("IsNode: {0}", root.IsNode()); Console.WriteLine("HasParent: {0}", root.HasParent()); Console.WriteLine("NumChildren: {0}", root.NumChildren()); Console.WriteLine("HasChild 'B: {0}", root.HasChild("B")); Console.WriteLine("HasChild 'List: {0}", root.HasChild("List")); Console.WriteLine(""); var child = root.GetList(); Console.WriteLine(child); Console.WriteLine("Child 1 -> t: {0}", child.Child(1).GetT()); Console.WriteLine("IsNode: {0}", child.IsNode()); Console.WriteLine("HasParent: {0}", child.HasParent()); Console.WriteLine("ChildIndex: {0}", child.ChildIndex()); Console.WriteLine("NumChildren: {0}", child.NumChildren()); }
public static bool Render(this Racr.AstNode n) { return(n.AttValue <bool>("Render")); }
public static int M(this Racr.AstNode n) { return((int)n.AttValue("M")); }
// Attribute Accessors public static Racr.AstNode Root(this Racr.AstNode n) { return(n.AttValue <Racr.AstNode>("Root")); }
public static bool N(this Racr.AstNode n) { return((bool)n.AttValue("N")); }
public static Racr.AstNode LLookup(this Racr.AstNode n, string name) { return(n.AttValue <Racr.AstNode>("LLookup", name)); }
static void TestFoo() { var spec = new MySpec(); var root = new Racr.AstNode(spec, "A", new Racr.AstList( new B(spec, "abc"), new B(spec, "123"), new B(spec, "xyz")), new Racr.AstNode(spec, "C"), "hiya"); root.ForEachChild((i, o) => { var node = o as Racr.AstNode; if (node != null) { Console.WriteLine("{0}: {1}", i, node.NodeType()); } else { Console.WriteLine("{0}: {1}", i, o); } }, new Racr.Range(2)); Console.WriteLine("---"); Console.WriteLine("M: {0}", root.M()); Console.WriteLine("N: {0}", root.N()); Console.WriteLine("a: {0}", root.AttValue("a")); Console.WriteLine("b: {0}", root.AttValue("b", 3)); Console.WriteLine("kids: {0}", root.AttValue("kids")); var index = root.GetList().Child(1).AttValue <int>("bar", 3); Console.WriteLine("index: {0}", index); Console.WriteLine("---"); var c = root.FindChild((i, o) => { return(i == 2); }) as Racr.AstNode; Console.WriteLine("{0}", c.NodeType()); Console.WriteLine("---"); Console.WriteLine(root); Console.WriteLine("NodeType: {0}", root.NodeType()); Console.WriteLine("IsNode: {0}", root.IsNode()); Console.WriteLine("HasParent: {0}", root.HasParent()); Console.WriteLine("NumChildren: {0}", root.NumChildren()); Console.WriteLine("HasChild 'B: {0}", root.HasChild("B")); Console.WriteLine("HasChild 'List: {0}", root.HasChild("List")); Console.WriteLine(""); var child = root.GetList(); Console.WriteLine(child); Console.WriteLine("Child 1 -> t: {0}", child.Child(1).GetT()); Console.WriteLine("IsNode: {0}", child.IsNode()); Console.WriteLine("HasParent: {0}", child.HasParent()); Console.WriteLine("ChildIndex: {0}", child.ChildIndex()); Console.WriteLine("NumChildren: {0}", child.NumChildren()); }
public static bool IsErrorQuestion(this Racr.AstNode n) { return(n.AttValue <bool>("IsErrorQuestion")); }
public static double Eval(this Racr.AstNode n) { return(n.AttValue <double>("Eval")); }
public static bool IsActive(this Racr.AstNode n) { return(n.AttValue <bool>("IsActive")); }
static Box Widget(this Ast n) { return(n.AttValue <Box>("Widget")); }
// Attribute Accessors: static QDialog Dialog(this Ast n) { return(n.AttValue <QDialog>("Dialog")); }
public static ValueTypes Type(this Racr.AstNode n) { return(n.AttValue <ValueTypes>("Type")); }
static bool Render(this Ast n) { return(n.AttValue <bool>("Render")); }
public static string SExpr(this Ast n) { return(n.AttValue <string>("SExpr")); }