[jira] [Updated] (OFBIZ-10806) Groovy Base script redundancy

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Updated] (OFBIZ-10806) Groovy Base script redundancy

Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-10806?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mathieu Lirzin updated OFBIZ-10806:
-----------------------------------
    Description:
According to [Groovy documentation|http://docs.groovy-lang.org/latest/html/documentation/#_script_base_classes] the following construction:

{code:java}
CompilerConfiguration conf = new CompilerConfiguration();
conf.setScriptBaseClass(scriptBaseClass);
groovyClassLoader = new GroovyClassLoader(GroovyUtil.class.getClassLoader(), conf);
{code}

is equivalent to running the a script containing the {{@BaseScript}} annotation.

In {{org.apache.ofbiz.base.util.GroovyUtil}} instead of choosing one solution, we are doing both. :-)


  was:
According to [Groovy documentation|http://docs.groovy-lang.org/latest/html/documentation/#_script_base_classes] the following construction:

{code:java}
CompilerConfiguration conf = new CompilerConfiguration();
conf.setScriptBaseClass(scriptBaseClass);
groovyClassLoader = new GroovyClassLoader(GroovyUtil.class.getClassLoader(), conf);
{code}

is equivalent to running the a script containing the {{@BaseScript}} annotation. In {{org.apache.ofbiz.base.util.GroovyUtil}} instead of choosing one solution, we are doing both. :-)



> Groovy Base script redundancy
> -----------------------------
>
>                 Key: OFBIZ-10806
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-10806
>             Project: OFBiz
>          Issue Type: Improvement
>          Components: framework
>    Affects Versions: Trunk
>            Reporter: Mathieu Lirzin
>            Priority: Minor
>             Fix For: Upcoming Branch
>
>
> According to [Groovy documentation|http://docs.groovy-lang.org/latest/html/documentation/#_script_base_classes] the following construction:
> {code:java}
> CompilerConfiguration conf = new CompilerConfiguration();
> conf.setScriptBaseClass(scriptBaseClass);
> groovyClassLoader = new GroovyClassLoader(GroovyUtil.class.getClassLoader(), conf);
> {code}
> is equivalent to running the a script containing the {{@BaseScript}} annotation.
> In {{org.apache.ofbiz.base.util.GroovyUtil}} instead of choosing one solution, we are doing both. :-)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)