summaryrefslogtreecommitdiff
path: root/bkucommon/src
diff options
context:
space:
mode:
authortkellner <tkellner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2013-11-28 18:57:07 +0000
committertkellner <tkellner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2013-11-28 18:57:07 +0000
commit30fab5462e0f38d1cc98acf3b67d43b74335ee1f (patch)
tree419f26f847785adcd5bd920962a6abb04ad63d4a /bkucommon/src
parentb45f1a0bfc420753ac18b1c566ad74facfb54b29 (diff)
downloadmocca-30fab5462e0f38d1cc98acf3b67d43b74335ee1f.tar.gz
mocca-30fab5462e0f38d1cc98acf3b67d43b74335ee1f.tar.bz2
mocca-30fab5462e0f38d1cc98acf3b67d43b74335ee1f.zip
Rename some constants
git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@1239 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4
Diffstat (limited to 'bkucommon/src')
-rw-r--r--bkucommon/src/main/java/at/gv/egiz/bku/binding/DataUrlConnectionImpl.java8
-rw-r--r--bkucommon/src/main/java/at/gv/egiz/bku/binding/HTTPBindingProcessorImpl.java4
-rw-r--r--bkucommon/src/main/java/at/gv/egiz/bku/binding/HttpUtil.java8
3 files changed, 10 insertions, 10 deletions
diff --git a/bkucommon/src/main/java/at/gv/egiz/bku/binding/DataUrlConnectionImpl.java b/bkucommon/src/main/java/at/gv/egiz/bku/binding/DataUrlConnectionImpl.java
index 5f343f40..21a8fc64 100644
--- a/bkucommon/src/main/java/at/gv/egiz/bku/binding/DataUrlConnectionImpl.java
+++ b/bkucommon/src/main/java/at/gv/egiz/bku/binding/DataUrlConnectionImpl.java
@@ -168,10 +168,10 @@ public class DataUrlConnectionImpl extends HttpsDataURLConnection {
HttpUtil.APPLICATION_URL_ENCODED);
} else {
log.debug("Setting DataURL Content-Type to {}.",
- HttpUtil.MULTIPART_FOTMDATA_BOUNDARY);
+ HttpUtil.MULTIPART_FORMDATA_BOUNDARY);
connection.addRequestProperty(HttpUtil.HTTP_HEADER_CONTENT_TYPE,
- HttpUtil.MULTIPART_FOTMDATA + HttpUtil.SEPERATOR[0]
- + HttpUtil.MULTIPART_FOTMDATA_BOUNDARY + "=" + boundary);
+ HttpUtil.MULTIPART_FORMDATA + HttpUtil.SEPARATOR[0]
+ + HttpUtil.MULTIPART_FORMDATA_BOUNDARY + "=" + boundary);
}
log.trace("Connecting to URL '{}'.", url);
connection.connect();
@@ -326,7 +326,7 @@ public class DataUrlConnectionImpl extends HttpsDataURLConnection {
StringBuffer value = new StringBuffer();
for (String val : httpHeaders.get(key)) {
value.append(val);
- value.append(HttpUtil.SEPERATOR[0]);
+ value.append(HttpUtil.SEPARATOR[0]);
}
String valString = value.substring(0, value.length() - 1);
if ((key != null) && (value.length() > 0)) {
diff --git a/bkucommon/src/main/java/at/gv/egiz/bku/binding/HTTPBindingProcessorImpl.java b/bkucommon/src/main/java/at/gv/egiz/bku/binding/HTTPBindingProcessorImpl.java
index d4ed4f1e..6f1f2840 100644
--- a/bkucommon/src/main/java/at/gv/egiz/bku/binding/HTTPBindingProcessorImpl.java
+++ b/bkucommon/src/main/java/at/gv/egiz/bku/binding/HTTPBindingProcessorImpl.java
@@ -411,7 +411,7 @@ public class HTTPBindingProcessorImpl extends AbstractBindingProcessor implement
String charSet = HttpUtil.getCharset(contentType, false);
if (charSet != null) {
contentType = contentType.substring(0, contentType
- .lastIndexOf(HttpUtil.SEPERATOR[0]));
+ .lastIndexOf(HttpUtil.SEPARATOR[0]));
}
for (Iterator<String> header = fp.getHeaderNames(); header.hasNext();) {
if (HttpUtil.CONTENT_TRANSFER_ENCODING
@@ -459,7 +459,7 @@ public class HTTPBindingProcessorImpl extends AbstractBindingProcessor implement
log.debug("Got dataurl response content type: {}.", contentType);
if (contentType != null) {
if ((contentType.startsWith(HttpUtil.APPLICATION_URL_ENCODED))
- || (contentType.startsWith(HttpUtil.MULTIPART_FOTMDATA))) {
+ || (contentType.startsWith(HttpUtil.MULTIPART_FORMDATA))) {
log.debug("Detected SL Request in dataurl response.");
// process headers and request
setHTTPHeaders(dataUrlResponse.getResponseHeaders());
diff --git a/bkucommon/src/main/java/at/gv/egiz/bku/binding/HttpUtil.java b/bkucommon/src/main/java/at/gv/egiz/bku/binding/HttpUtil.java
index 152b007b..8d3a8112 100644
--- a/bkucommon/src/main/java/at/gv/egiz/bku/binding/HttpUtil.java
+++ b/bkucommon/src/main/java/at/gv/egiz/bku/binding/HttpUtil.java
@@ -42,15 +42,15 @@ public class HttpUtil {
public final static String HTTP_HEADER_REFERER = "Referer";
public static final String HTTP_HEADER_SIGNATURE_LAYOUT = "SignatureLayout";
public final static String CONTENT_TRANSFER_ENCODING = "Content-Transfer-Encoding";
- public final static String MULTIPART_FOTMDATA = "multipart/form-data";
- public final static String MULTIPART_FOTMDATA_BOUNDARY = "boundary";
+ public final static String MULTIPART_FORMDATA = "multipart/form-data";
+ public final static String MULTIPART_FORMDATA_BOUNDARY = "boundary";
public final static String TXT_XML = "text/xml";
public final static String TXT_PLAIN = "text/plain";
public final static String TXT_HTML = "text/html";
public final static String APPLICATION_URL_ENCODED = "application/x-www-form-urlencoded";
public final static String HTTP_HEADER_LOCATION = "Location";
- public final static char[] SEPERATOR = { ';' };
+ public final static char[] SEPARATOR = { ';' };
/**
* Extracts charset from a content type header.
@@ -64,7 +64,7 @@ public class HttpUtil {
boolean replaceNullWithDefault) {
ParameterParser pf = new ParameterParser();
pf.setLowerCaseNames(true);
- Map<?, ?> map = pf.parse(contentType, SEPERATOR);
+ Map<?, ?> map = pf.parse(contentType, SEPARATOR);
String retVal = (String) map.get(CHAR_SET);
if ((retVal == null) && (replaceNullWithDefault)) {
if (map.containsKey(APPLICATION_URL_ENCODED)) {