commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nia...@apache.org
Subject svn commit: r354502 - in /jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources: Message.java impl/BasicMessage.java
Date Tue, 06 Dec 2005 19:11:51 GMT
Author: niallp
Date: Tue Dec  6 11:11:40 2005
New Revision: 354502

URL: http://svn.apache.org/viewcvs?rev=354502&view=rev
Log:
Add getResourcesName() to the Messages API (see bug 37713)

Modified:
    jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/Message.java
    jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/impl/BasicMessage.java

Modified: jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/Message.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/Message.java?rev=354502&r1=354501&r2=354502&view=diff
==============================================================================
--- jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/Message.java
(original)
+++ jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/Message.java
Tue Dec  6 11:11:40 2005
@@ -34,6 +34,14 @@
 public interface Message {
 
     /**
+     * <p>Return the logical name of the {@link org.apache.commons.resources.Resources}

+     * instance this message is associated with.</p>
+     *
+     * @return The name of the resources instance.
+     */
+    public String getResourcesName();
+
+    /**
      * @return Get the message key for this message.
      */
     public String getKey();

Modified: jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/impl/BasicMessage.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/impl/BasicMessage.java?rev=354502&r1=354501&r2=354502&view=diff
==============================================================================
--- jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/impl/BasicMessage.java
(original)
+++ jakarta/commons/proper/resources/trunk/src/java/org/apache/commons/resources/impl/BasicMessage.java
Tue Dec  6 11:11:40 2005
@@ -33,6 +33,12 @@
  * Orginally based on org.apache.http.action.ActionMessage, Revision 1.5.
  */
 public class BasicMessage implements Serializable, Message {
+
+    /**
+     * The logical name of the {@link org.apache.commons.resources.Resources} 
+     * instance this message is associated with (optional).
+     */
+    private String resourcesName;
     
     /**
      * The message key for this message.
@@ -131,6 +137,26 @@
     public BasicMessage(String key, Object[] values) {
         this.key = key;
         this.values = values;
+    }
+
+    /**
+     * <p>Return the logical name of the {@link org.apache.commons.resources.Resources}

+     * instance this message is associated with.</p>
+     *
+     * @return The name of the resources instance.
+     */
+    public String getResourcesName() {
+        return resourcesName;
+    }
+
+    /**
+     * <p>Set the logical name of the {@link org.apache.commons.resources.Resources}

+     * instance this message is associated with.</p>
+     *
+     * @param resourcesName The name of the resources instance.
+     */
+    public void setResourcesName(String resourcesName) {
+        this.resourcesName = resourcesName;
     }
 
     /**



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message