5555 * @author Matthew Hawthorne
5656 * @author Martin Cooper
5757 * @author <a href="mailto:jeremias@apache.org">Jeremias Maerki</a>
58- * @version $Id: FilenameUtils.java,v 1.17 2004/10/29 21:34:56 bayard Exp $
58+ * @version $Id: FilenameUtils.java,v 1.18 2004/10/29 21:38:49 bayard Exp $
5959 * @since Commons IO 1.1
6060 */
6161public class FilenameUtils {
@@ -68,7 +68,7 @@ public class FilenameUtils {
6868 /**
6969 * Standard separator string used when internalizing paths.
7070 */
71- // KILL
71+ // KILL? It's here to match symmetry of File.separator and to promote its use
7272 private static final String INTERNAL_SEPARATOR = "/" ;
7373
7474 /**
@@ -202,9 +202,7 @@ public static String removePath(String filepath) {
202202 * @return the filename minus path
203203 */
204204 // KILL: Why allow the char to be specified?
205- public static String removePath (
206- String filepath ,
207- char fileSeparatorChar ) {
205+ public static String removePath ( String filepath , char fileSeparatorChar ) {
208206 int index = filepath .lastIndexOf (fileSeparatorChar );
209207
210208 if (-1 == index ) {
@@ -244,9 +242,7 @@ public static String getPath(String filepath) {
244242 * @return the filename minus path
245243 */
246244 // KILL: Why allow the char to be specified?
247- public static String getPath (
248- String filepath ,
249- char fileSeparatorChar ) {
245+ public static String getPath ( String filepath , char fileSeparatorChar ) {
250246 int index = filepath .lastIndexOf (fileSeparatorChar );
251247 if (-1 == index ) {
252248 return "" ;
@@ -340,8 +336,8 @@ public static String normalize(String path) {
340336 * @param lookupPath the base path to attach to
341337 * @param path path the second path to attach to the first
342338 * @return The concatenated paths, or null if error occurs
343- * @todo UNIX/Windows only. Is this a problem?
344339 */
340+ // TODO UNIX/Windows only. Is this a problem?
345341 public static String catPath (String lookupPath , String path ) {
346342 // Cut off the last slash and everything beyond
347343 int index = indexOfLastPathSeparator (lookupPath );
@@ -391,8 +387,8 @@ public static int indexOfLastPathSeparator(String path) {
391387 * <code>filename</code> is relative.
392388 * @param filename Absolute or relative file path to resolve.
393389 * @return The canonical <code>File</code> of <code>filename</code>.
394- * @todo Decide whether this is worth keeping?
395390 */
391+ // KILL? Decide whether this is worth keeping?
396392 public static File resolveFile (File baseFile , String filename ) {
397393 String filenm = filename ;
398394 if ('/' != File .separatorChar ) {
@@ -460,7 +456,7 @@ public static File resolveFile(File baseFile, String filename) {
460456 * @param path The path to be internalized.
461457 * @return The internalized path.
462458 */
463- // KILL: Inline into the one place this is used
459+ // KILL: Inline into the one place this is used?
464460 private static String internalize (String path ) {
465461 return path .replace ('\\' , INTERNAL_SEPARATOR_CHAR );
466462 }
@@ -471,7 +467,7 @@ private static String internalize(String path) {
471467 * @param path The path to be externalized.
472468 * @return The externalized path.
473469 */
474- // KILL: Nothing uses this
470+ // KILL: Nothing uses this. It exists as symmetry of internalize and to promote its use
475471 private static String externalize (String path ) {
476472 if (INTERNAL_SEPARATOR_CHAR != File .separatorChar ) {
477473 path = path .replace (INTERNAL_SEPARATOR_CHAR , File .separatorChar );
0 commit comments