Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-3836

LINQ3: Add the virtual CanBeRenderedAsPath method to AstExpression

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Unknown Unknown
    • 2.14.0
    • None
    • LINQ3
    • None

    Description

      The LINQ3 translator at times need to know if an AstExpression can be rendered as a path of the form "$x.y.z" or "$$var.x.y.z".

      This question is most easily answered by defining a new virtual method

      • the default implementation of CanBeRenderedAsPath returns false
      • AstVarExpression overrides CanBeRenderedAsPath and returns true
      • AstGetFieldExpression overrides CanBeRenderedAsPath and returns true if the Input CanBeRenderedAsPath and the field name is safe to use in a path

      Attachments

        Activity

          People

            robert@mongodb.com Robert Stam
            robert@mongodb.com Robert Stam
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: