svn commit: r709886 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java

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

svn commit: r709886 - /ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java

adrianc
Author: adrianc
Date: Sun Nov  2 06:51:45 2008
New Revision: 709886

URL: http://svn.apache.org/viewvc?rev=709886&view=rev
Log:
Log simple method improvement - show source of log message.

Modified:
    ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java

Modified: ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java?rev=709886&r1=709885&r2=709886&view=diff
==============================================================================
--- ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java (original)
+++ ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/otherops/Log.java Sun Nov  2 06:51:45 2008
@@ -87,6 +87,16 @@
         }
         
         StringBuilder buf = new StringBuilder();
+        buf.append("[");
+        String methodLocation = this.simpleMethod.getFromLocation();
+        int pos = methodLocation.lastIndexOf("/");
+        if (pos != -1) {
+            methodLocation = methodLocation.substring(pos + 1);
+        }
+        buf.append(methodLocation);
+        buf.append("#");
+        buf.append(this.simpleMethod.getMethodName());
+        buf.append("] ");
         
         if (message != null) buf.append(message);