From 2882e14d19cfa58ea382083434210aaf0cfea3e3 Mon Sep 17 00:00:00 2001
From: wbauer <wbauer@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>
Date: Fri, 13 Mar 2009 07:49:49 +0000
Subject: Fixed Bug#405 and added according test case Fixed Bug#402 Added
 Feature#403

git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@320 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4
---
 .../bku/utils/urldereferencer/HTTPURLProtocolHandlerImpl.java    | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

(limited to 'utils/src/main/java')

diff --git a/utils/src/main/java/at/gv/egiz/bku/utils/urldereferencer/HTTPURLProtocolHandlerImpl.java b/utils/src/main/java/at/gv/egiz/bku/utils/urldereferencer/HTTPURLProtocolHandlerImpl.java
index 99f804b7..dfe7d5e6 100644
--- a/utils/src/main/java/at/gv/egiz/bku/utils/urldereferencer/HTTPURLProtocolHandlerImpl.java
+++ b/utils/src/main/java/at/gv/egiz/bku/utils/urldereferencer/HTTPURLProtocolHandlerImpl.java
@@ -81,6 +81,13 @@ public class HTTPURLProtocolHandlerImpl implements URLProtocolHandler {
         .getInputStream());
   }
 
+  /**
+   * 
+   * @param aUrl
+   * @param aContext
+   * @return
+   * @throws IOException if the data cannot be found or reading the stream failed.
+   */
   protected StreamData dereferenceFormData(String aUrl,
       URLDereferencerContext aContext) throws IOException {
     log.debug("Dereferencing formdata url: " + aUrl);
@@ -96,7 +103,7 @@ public class HTTPURLProtocolHandlerImpl implements URLProtocolHandler {
     if (is != null) {
       return new StreamData(aUrl, contentType, is);
     }
-    return null;
+     throw new IOException("Cannot dereference url: formdata not found");
   }
 
   @Override
-- 
cgit v1.2.3