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

Jeanne Waldman resolved TRINIDAD-133.
-------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.2.2-core

Completed: At revision: 561398   AND
Completed: At revision: 561404  
on trunk
Files changed:
    
myfaces/trinidad/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinExtension.java
    
myfaces/trinidad/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinImpl.java


> SkinExtension's getTranslatedValue performance improvement
> ----------------------------------------------------------
>
>                 Key: TRINIDAD-133
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-133
>             Project: MyFaces Trinidad
>          Issue Type: Improvement
>          Components: Skinning
>            Reporter: Jeanne Waldman
>            Assignee: Jeanne Waldman
>             Fix For: 1.2.2-core
>
>
>  I wanted to log this TODO  to improve the performance of SkinExtension's 
> getTranslatedValue:
> // TODO Cache base skin's non-null translatedValue with this skin to
> // make it faster.
>  /**
>     * Override of Skin.getTranslatedValue() which
>     * supports pulling translations from Skin and if not found from the base 
> Skin.
>   */
>   @Override
>   public Object getTranslatedValue(
>     LocaleContext lContext,
>     String        key
>     ) throws MissingResourceException
>   {
>     // Look for the skin's translated value (first bundle name, then 
> registered bundles)
>     // if that's not found, then look in the base skin's translated value.
>     // getCachedTranslatedValue will protect against MissingResourceExceptions
>     Object translatedValue = super.getCachedTranslatedValue(lContext, key);
>     // TODO Cache base skin's non-null translatedValue with this skin to
>     // make it faster.
>     if (translatedValue == null)
>       return getBaseSkin().getTranslatedValue(lContext, key);
>     else
>       return translatedValue;
>   }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to