import javax.jcr.nodetype.NodeType;
import org.apache.commons.io.IOUtils;
-import org.argeo.ArgeoException;
+import org.argeo.eclipse.ui.EclipseUiException;
import org.argeo.eclipse.ui.FileProvider;
/**
ba = IOUtils.toByteArray(fis);
} catch (Exception e) {
- throw new ArgeoException("Stream error while opening file", e);
+ throw new EclipseUiException("Stream error while opening file", e);
} finally {
IOUtils.closeQuietly(fis);
}
.getBinary().getStream();
return fis;
} catch (RepositoryException re) {
- throw new ArgeoException("Cannot get stream from file node for Id "
+ throw new EclipseUiException("Cannot get stream from file node for Id "
+ fileId, re);
}
}
// Sanity checks
if (result == null)
- throw new ArgeoException("File node not found for ID" + fileId);
+ throw new EclipseUiException("File node not found for ID" + fileId);
Node child = null;
}
if (!isValid)
- throw new ArgeoException(
+ throw new EclipseUiException(
"ERROR: In the current implemented model, '"
+ NodeType.NT_FILE
+ "' file node must have a child node named jcr:content "
return child;
} catch (RepositoryException re) {
- throw new ArgeoException("Erreur while getting file node of ID "
+ throw new EclipseUiException("Erreur while getting file node of ID "
+ fileId, re);
}
}