geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r681486 - /geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java
Date Thu, 31 Jul 2008 20:57:34 GMT
Author: gawor
Date: Thu Jul 31 13:57:33 2008
New Revision: 681486

URL: http://svn.apache.org/viewvc?rev=681486&view=rev
Log:
get the file name nicely

Modified:
    geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java

Modified: geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java?rev=681486&r1=681485&r2=681486&view=diff
==============================================================================
--- geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java
(original)
+++ geronimo/server/branches/2.1/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/logmanager/LogViewerPortlet.java
Thu Jul 31 13:57:33 2008
@@ -176,13 +176,7 @@
 
         public LogFile(String fullName) {
             this.fullName = fullName;
-            //todo: what if portla JVM has different separator than server JVM?
-            int pos = fullName.lastIndexOf(File.separatorChar);
-            if(pos > -1) {
-                name = fullName.substring(pos+1);
-            } else {
-                name = fullName;
-            }
+            this.name = (new File(fullName)).getName();
         }
 
         public String getFullName() {



Mime
View raw message