You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Radu Cotescu (JIRA)" <ji...@apache.org> on 2015/10/12 15:26:06 UTC

[jira] [Closed] (SLING-4957) Sightly RenderContextImpl contains utility methods that don't belong there

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

Radu Cotescu closed SLING-4957.
-------------------------------

> Sightly RenderContextImpl contains utility methods that don't belong there
> --------------------------------------------------------------------------
>
>                 Key: SLING-4957
>                 URL: https://issues.apache.org/jira/browse/SLING-4957
>             Project: Sling
>          Issue Type: Improvement
>          Components: Scripting
>    Affects Versions: Scripting Sightly Engine 1.0.2
>            Reporter: Vlad Bailescu
>            Assignee: Radu Cotescu
>            Priority: Minor
>             Fix For: Scripting Sightly Engine 1.0.6
>
>         Attachments: sling-4957.patch
>
>
> The current implementation of Sightly's {{RenderContext}} contains a lot of of utility methods ([example|https://github.com/apache/sling/blob/90d2ed9e42deb144a7f6e1610871e72726cd810a/bundles/scripting/sightly/engine/src/main/java/org/apache/sling/scripting/sightly/impl/engine/runtime/RenderContextImpl.java#L142]).
> These are not related to the actual context and belong to an utility class. They are also unrelated to a specific instance/state and should be made static.
> Refactoring these out of {{RenderContextImpl}} will allow us to avoid unnecessarily passing an object of this class to other parts of the code just to use these utility methods ([example|https://github.com/apache/sling/blob/90d2ed9e42deb144a7f6e1610871e72726cd810a/bundles/scripting/sightly/engine/src/main/java/org/apache/sling/scripting/sightly/impl/compiler/expression/node/BinaryOperator.java#L31]).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)