Skip to content
Snippets Groups Projects
Commit 810621a5 authored by brinn's avatar brinn
Browse files

fix: error message when creating link

fix: javadoc for createSymbolicLink() and createHardLink() (avoid confusion about what links where)

SVN: 10475
parent e1939edb
No related branches found
No related tags found
No related merge requests found
...@@ -354,7 +354,7 @@ public final class Unix ...@@ -354,7 +354,7 @@ public final class Unix
String errorMessage) String errorMessage)
{ {
throw new IOExceptionUnchecked(new IOException(String.format( throw new IOExceptionUnchecked(new IOException(String.format(
"Creating %s link '%s' -> '%s': %s", type, source, target, errorMessage))); "Creating %s link '%s' -> '%s': %s", type, target, source, errorMessage)));
} }
private static void throwStatException(String filename, String errorMessage) private static void throwStatException(String filename, String errorMessage)
...@@ -525,10 +525,10 @@ public final class Unix ...@@ -525,10 +525,10 @@ public final class Unix
// //
/** /**
* Creates a hard link from <var>fileName</var> to <var>linkName</var>. * Creates a hard link <var>linkName</var> that points to <var>fileName</var>.
* *
* @throws IOExceptionUnchecked If the underlying system call fails, e.g. because * @throws IOExceptionUnchecked If the underlying system call fails, e.g. because
* <var>fileName</var> does not exist or because <var>linkName</var> already exists. * <var>linkName</var> already exists or <var>fileName</var> does not exist.
*/ */
public static final void createHardLink(String fileName, String linkName) public static final void createHardLink(String fileName, String linkName)
throws IOExceptionUnchecked throws IOExceptionUnchecked
...@@ -549,10 +549,10 @@ public final class Unix ...@@ -549,10 +549,10 @@ public final class Unix
} }
/** /**
* Creates a symbolic link from <var>fileName</var> to <var>linkName</var>. * Creates a symbolic link <var>linkName</var> that points to <var>fileName</var>.
* *
* @throws IOExceptionUnchecked If the underlying system call fails, e.g. because * @throws IOExceptionUnchecked If the underlying system call fails, e.g. because
* <var>fileName</var> does not exist or because <var>linkName</var> already exists. * <var>linkName</var> already exists.
*/ */
public static final void createSymbolicLink(String fileName, String linkName) public static final void createSymbolicLink(String fileName, String linkName)
throws IOExceptionUnchecked throws IOExceptionUnchecked
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment