Revision: 5866
http://jython.svn.sourceforge.net/jython/?rev=5866&view=rev
Author: otmarhumbel
Date: 2009-01-07 17:39:42 +0000 (Wed, 07 Jan 2009)
Log Message:
-----------
small refactoring and javadoc
Modified Paths:
--------------
trunk/installer/src/java/org/python/util/install/driver/Autotest.java
Modified: trunk/installer/src/java/org/python/util/install/driver/Autotest.java
===================================================================
--- trunk/installer/src/java/org/python/util/install/driver/Autotest.java 2009-01-07 08:28:57 UTC (rev 5865)
+++ trunk/installer/src/java/org/python/util/install/driver/Autotest.java 2009-01-07 17:39:42 UTC (rev 5866)
@@ -30,7 +30,7 @@
*/
protected Autotest(InstallerCommandLine commandLine) throws IOException, DriverException {
_count++;
- setName();
+ buildName();
if (_rootDirectory == null) {
createRootDirectory();
}
@@ -161,17 +161,24 @@
// private stuff
//
- private void setName() {
- String countAsString = "";
+ /**
+ * build a test name containing some special characters (which will be used to create the target
+ * directory), and store it into <code>_name</code>.
+ */
+ private void buildName() {
+ StringBuilder b = new StringBuilder(24);
if (_count <= 99) {
- countAsString += "0";
+ b.append('0');
}
if (_count <= 9) {
- countAsString += "0";
+ b.append('0');
}
- countAsString += _count;
- // explicitly use a blank in the directory name, to nail down some platform specific problems
- _name = countAsString + " " + getNameSuffix() + "_";
+ b.append(_count);
+ // explicitly use a blank, to nail down some platform specific problems
+ b.append(' ');
+ b.append(getNameSuffix());
+ b.append('_');
+ _name = b.toString();
}
/**
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|