View over a Qil operator having two children.
Don't construct QIL nodes directly; instead, use the QilFactory.
Наследование: QilNode
Пример #1
0
 protected virtual QilNode VisitXsltCopy(QilBinary n)
 {
     return(VisitChildren(n));
 }
Пример #2
0
 public XmlQueryType CheckDeref(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.StringX);
     return XmlQueryTypeFactory.ElementS;
 }
Пример #3
0
 public XmlQueryType CheckNamespaceDecl(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.StringX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.StringX);
     return XmlQueryTypeFactory.Namespace;
 }
Пример #4
0
 public XmlQueryType CheckStrParseQName(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.StringX);
     Check(node.Right.XmlType.IsSubtypeOf(XmlQueryTypeFactory.StringX) || node.Right.XmlType.IsSubtypeOf(XmlQueryTypeFactory.NamespaceS),
           node, "StrParseQName must take either a string or a list of namespace as its second argument");
     return XmlQueryTypeFactory.QNameX;
 }
Пример #5
0
 public XmlQueryType CheckAfter(QilBinary node) {
     return CheckIs(node);
 }
Пример #6
0
 public XmlQueryType CheckUnion(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return DistinctType(XmlQueryTypeFactory.Sequence(node.Left.XmlType, node.Right.XmlType));
 }
Пример #7
0
 public XmlQueryType CheckSubtract(QilBinary node) {
     return CheckAdd(node);
 }
Пример #8
0
 public XmlQueryType CheckDifference(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return(XmlQueryTypeFactory.AtMost(node.Left.XmlType, node.Left.XmlType.Cardinality));
 }
Пример #9
0
 public XmlQueryType CheckSubtract(QilBinary node)
 {
     return(CheckAdd(node));
 }
Пример #10
0
 public XmlQueryType CheckUnion(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return(DistinctType(XmlQueryTypeFactory.Sequence(node.Left.XmlType, node.Right.XmlType)));
 }
Пример #11
0
 public XmlQueryType CheckIntersection(QilBinary node)
 {
     return(CheckUnion(node));
 }
Пример #12
0
 public XmlQueryType CheckOr(QilBinary node)
 {
     return(CheckAnd(node));
 }
Пример #13
0
 private void CheckNotDisjoint(QilBinary node)
 {
     Check(node.Left.XmlType.IsSubtypeOf(node.Right.XmlType) || node.Right.XmlType.IsSubtypeOf(node.Left.XmlType), node,
           "Node must not have arguments with disjoint types " + node.Left.XmlType + " and " + node.Right.XmlType);
 }
Пример #14
0
 public XmlQueryType CheckXsltCopy(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeS);
     return(XmlQueryTypeFactory.Choice(node.Left.XmlType, node.Right.XmlType));
 }
Пример #15
0
 protected virtual QilNode VisitRtfCtor(QilBinary n) { return VisitChildren(n); }
Пример #16
0
 public XmlQueryType CheckMultiply(QilBinary node)
 {
     return(CheckAdd(node));
 }
Пример #17
0
 //-----------------------------------------------
 // boolean operators
 //-----------------------------------------------
 public XmlQueryType CheckAnd(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.BooleanX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.BooleanX);
     return XmlQueryTypeFactory.BooleanX;
 }
Пример #18
0
 public XmlQueryType CheckDivide(QilBinary node)
 {
     return(CheckAdd(node));
 }
Пример #19
0
 public XmlQueryType CheckDifference(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return XmlQueryTypeFactory.AtMost(node.Left.XmlType, node.Left.XmlType.Cardinality);
 }
Пример #20
0
 public XmlQueryType CheckModulo(QilBinary node)
 {
     return(CheckAdd(node));
 }
Пример #21
0
 public XmlQueryType CheckDivide(QilBinary node) {
     return CheckAdd(node);
 }
Пример #22
0
 public XmlQueryType CheckLe(QilBinary node)
 {
     return(CheckNe(node));
 }
Пример #23
0
 public XmlQueryType CheckLe(QilBinary node) {
     return CheckNe(node);
 }
Пример #24
0
 //-----------------------------------------------
 // node comparison operators
 //-----------------------------------------------
 public XmlQueryType CheckIs(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtf);
     return(XmlQueryTypeFactory.BooleanX);
 }
Пример #25
0
 public XmlQueryType CheckAttribute(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.QNameX);
     return XmlQueryTypeFactory.AttributeQ;
 }
Пример #26
0
 public XmlQueryType CheckAfter(QilBinary node)
 {
     return(CheckIs(node));
 }
Пример #27
0
 public XmlQueryType CheckAttributeCtor(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.QNameX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return XmlQueryTypeFactory.UntypedAttribute;
 }
Пример #28
0
 public XmlQueryType CheckBefore(QilBinary node)
 {
     return(CheckIs(node));
 }
Пример #29
0
 public XmlQueryType CheckXsltCopy(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeS);
     return XmlQueryTypeFactory.Choice(node.Left.XmlType, node.Right.XmlType);
 }
Пример #30
0
 public XmlQueryType CheckAttribute(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.QNameX);
     return(XmlQueryTypeFactory.AttributeQ);
 }
Пример #31
0
 protected virtual QilNode VisitNamespaceDecl(QilBinary n) { return VisitChildren(n); }
Пример #32
0
 public XmlQueryType CheckNodeRange(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtf);
     return(XmlQueryTypeFactory.Choice(node.Left.XmlType, XmlQueryTypeFactory.ContentS, node.Right.XmlType));
 }
Пример #33
0
 protected virtual QilNode VisitXsltCopy(QilBinary n) { return VisitChildren(n); }
Пример #34
0
 public XmlQueryType CheckDeref(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.StringX);
     return(XmlQueryTypeFactory.ElementS);
 }
Пример #35
0
 public XmlQueryType CheckOr(QilBinary node) {
     return CheckAnd(node);
 }
Пример #36
0
 //-----------------------------------------------
 // XML construction
 //-----------------------------------------------
 public XmlQueryType CheckElementCtor(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.QNameX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return(XmlQueryTypeFactory.UntypedElement);
 }
Пример #37
0
 public XmlQueryType CheckIntersection(QilBinary node) {
     return CheckUnion(node);
 }
Пример #38
0
 public XmlQueryType CheckAttributeCtor(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.QNameX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return(XmlQueryTypeFactory.UntypedAttribute);
 }
Пример #39
0
 public XmlQueryType CheckAdd(QilBinary node) {
     CheckNumericX(node.Left);
     CheckNumericX(node.Right);
     CheckNotDisjoint(node);
     return node.Left.XmlType.TypeCode == XmlTypeCode.None ? node.Right.XmlType : node.Left.XmlType;
 }
Пример #40
0
 public XmlQueryType CheckPICtor(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.StringX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return(XmlQueryTypeFactory.PI);
 }
Пример #41
0
 public XmlQueryType CheckMultiply(QilBinary node) {
     return CheckAdd(node);
 }
Пример #42
0
 public XmlQueryType CheckNamespaceDecl(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.StringX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.StringX);
     return(XmlQueryTypeFactory.Namespace);
 }
Пример #43
0
 public XmlQueryType CheckModulo(QilBinary node) {
     return CheckAdd(node);
 }
Пример #44
0
 public XmlQueryType CheckRtfCtor(QilBinary node)
 {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckClassAndNodeType(node.Right, typeof(QilLiteral), QilNodeType.LiteralString);
     return(XmlQueryTypeFactory.Node);
 }
Пример #45
0
 //-----------------------------------------------
 // value comparison operators
 //-----------------------------------------------
 public XmlQueryType CheckNe(QilBinary node) {
     CheckAtomicX(node.Left);
     CheckAtomicX(node.Right);
     CheckNotDisjoint(node);
     return XmlQueryTypeFactory.BooleanX;
 }
Пример #46
0
 protected override QilNode VisitElementCtor(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #47
0
 //-----------------------------------------------
 // node comparison operators
 //-----------------------------------------------
 public XmlQueryType CheckIs(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtf);
     return XmlQueryTypeFactory.BooleanX;
 }
Пример #48
0
 protected override QilNode VisitAttributeCtor(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #49
0
 public XmlQueryType CheckBefore(QilBinary node) {
     return CheckIs(node);
 }
Пример #50
0
 protected override QilNode VisitNamespaceDecl(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #51
0
 public XmlQueryType CheckNodeRange(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtf);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtf);
     return XmlQueryTypeFactory.Choice(node.Left.XmlType, XmlQueryTypeFactory.ContentS, node.Right.XmlType);
 }
Пример #52
0
 protected override QilNode VisitIntersection(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #53
0
 //-----------------------------------------------
 // XML construction
 //-----------------------------------------------
 public XmlQueryType CheckElementCtor(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.QNameX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return XmlQueryTypeFactory.UntypedElement;
 }
Пример #54
0
 protected override QilNode VisitStrParseQName(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #55
0
 public XmlQueryType CheckPICtor(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.StringX);
     CheckXmlType(node.Right, XmlQueryTypeFactory.NodeNotRtfS);
     return XmlQueryTypeFactory.PI;
 }
Пример #56
0
 protected override QilNode VisitGe(QilBinary n)
 {
     return(NoReplace(n));
 }
Пример #57
0
 public XmlQueryType CheckRtfCtor(QilBinary node) {
     CheckXmlType(node.Left, XmlQueryTypeFactory.NodeNotRtfS);
     CheckClassAndNodeType(node.Right, typeof(QilLiteral), QilNodeType.LiteralString);
     return XmlQueryTypeFactory.Node;
 }
Пример #58
0
 protected virtual QilNode VisitAttributeCtor(QilBinary n) { return VisitChildren(n); }
Пример #59
0
 private void CheckNotDisjoint(QilBinary node) {
     Check(node.Left.XmlType.IsSubtypeOf(node.Right.XmlType) || node.Right.XmlType.IsSubtypeOf(node.Left.XmlType), node,
           "Node must not have arguments with disjoint types " + node.Left.XmlType + " and " + node.Right.XmlType);
 }
Пример #60
0
 protected virtual QilNode VisitRtfCtor(QilBinary n)
 {
     return(VisitChildren(n));
 }