struts-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lukaszlen...@apache.org
Subject [04/12] struts git commit: Injects factory instead of the provider
Date Thu, 16 Mar 2017 10:09:38 GMT
Injects factory instead of the provider


Project: http://git-wip-us.apache.org/repos/asf/struts/repo
Commit: http://git-wip-us.apache.org/repos/asf/struts/commit/3b738ad3
Tree: http://git-wip-us.apache.org/repos/asf/struts/tree/3b738ad3
Diff: http://git-wip-us.apache.org/repos/asf/struts/diff/3b738ad3

Branch: refs/heads/master
Commit: 3b738ad3ef01c434dbd673d5dca4659aa5779e7d
Parents: 09be1b9
Author: Lukasz Lenart <lukaszlenart@apache.org>
Authored: Wed Mar 15 08:53:35 2017 +0100
Committer: Lukasz Lenart <lukaszlenart@apache.org>
Committed: Wed Mar 15 08:53:35 2017 +0100

----------------------------------------------------------------------
 .../java/com/opensymphony/xwork2/TextProviderSupport.java | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/struts/blob/3b738ad3/core/src/main/java/com/opensymphony/xwork2/TextProviderSupport.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/com/opensymphony/xwork2/TextProviderSupport.java b/core/src/main/java/com/opensymphony/xwork2/TextProviderSupport.java
index cf177d3..528a910 100644
--- a/core/src/main/java/com/opensymphony/xwork2/TextProviderSupport.java
+++ b/core/src/main/java/com/opensymphony/xwork2/TextProviderSupport.java
@@ -67,6 +67,7 @@ public class TextProviderSupport implements ResourceBundleTextProvider {
     /**
      * @param bundle the resource bundle.
      */
+    @Override
     public void setBundle(ResourceBundle bundle) {
         this.bundle = bundle;
     }
@@ -74,20 +75,25 @@ public class TextProviderSupport implements ResourceBundleTextProvider
{
     /**
      * @param clazz a clazz to use for reading the resource bundle.
      */
+    @Override
     public void setClazz(Class clazz) {
         this.clazz = clazz;
     }
 
-
     /**
      * @param localeProvider a locale provider.
      */
-    @Inject
+    @Override
     public void setLocaleProvider(LocaleProvider localeProvider) {
         this.localeProvider = localeProvider;
     }
 
     @Inject
+    public void setLocaleProviderFactory(LocaleProviderFactory localeProviderFactory) {
+        this.localeProvider = localeProviderFactory.createLocaleProvider();
+    }
+
+    @Inject
     public void setLocalizedTextProvider(LocalizedTextProvider localizedTextProvider) {
         this.localizedTextProvider = localizedTextProvider;
     }


Mime
View raw message