remote: exceptions
[fanfix.git] / src / be / nikiroo / fanfix / library / RemoteLibraryException.java
diff --git a/src/be/nikiroo/fanfix/library/RemoteLibraryException.java b/src/be/nikiroo/fanfix/library/RemoteLibraryException.java
new file mode 100644 (file)
index 0000000..fb86787
--- /dev/null
@@ -0,0 +1,27 @@
+package be.nikiroo.fanfix.library;
+
+import java.io.IOException;
+
+/**
+ * Exceptions sent from remote to local.
+ * 
+ * @author niki
+ */
+public class RemoteLibraryException extends IOException {
+       private static final long serialVersionUID = 1L;
+
+       /**
+        * Wrap an {@link IOException} to allow it to pass across the network.
+        * 
+        * @param cause
+        *            the excption to wrap
+        */
+       public RemoteLibraryException(IOException cause) {
+               super(cause);
+       }
+
+       @Override
+       public synchronized IOException getCause() {
+               return (IOException) super.getCause();
+       }
+}