Groovy
  1. Groovy
  2. GROOVY-2505

Need to be able to either convert a String to a GString or to evaluate a String.

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 1.5.1
    • Fix Version/s: None
    • Component/s: groovy-jdk
    • Labels:
      None

      Description

      Several times it has been asked on the mailing list on how to either convert a String to a GString or to evaluate a String as a GString. The need arises when a String comes in from an external source and contains a GString expression, for example an XML file or a Configuration file. Currently one needs to either invoke the GroovyShell or the SimpleTemplateEngine to accomplish the task. In both cases this takes several lines of code and is not intuitively obvious.

      One could ether add a GDK method to String such as "evaluate" (which in my humble opinion would be the nicest) or provide a conversion of the form "String as GString"

        Activity

        Erik Husby created issue -
        Pascal Schumacher made changes -
        Field Original Value New Value
        Resolution Won't Fix [ 2 ]
        Status Open [ 1 ] Closed [ 6 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 13:32:57 UTC 2015 [ 1428240777691 ]
        Mark Thomas made changes -
        Workflow jira [ 12731559 ] Default workflow, editable Closed status [ 12741113 ]
        Mark Thomas made changes -
        Project Import Mon Apr 06 02:11:23 UTC 2015 [ 1428286283443 ]
        Mark Thomas made changes -
        Workflow jira [ 12967710 ] Default workflow, editable Closed status [ 12975315 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Erik Husby
          • Votes:
            13 Vote for this issue
            Watchers:
            11 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development