Class HTTPHeaders
- java.lang.Object
-
- com.ibm.di.connector.WSReceiverServerConnector.HTTPHeaders
-
public class HTTPHeaders extends java.lang.ObjectHttpHeader is an object that aides in the creation of a response header.
-
-
Constructor Summary
Constructors Constructor Description HTTPHeaders()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static booleanmatches(byte[] buf, byte[] target)The method accepts two byte array and returns true if they match.static booleanmatches(byte[] buf, int bufIdx, byte[] target)The method accepts two byte array and returns true if the part of the first one starting from position bufIdx matches the second one.static booleanmatchesCase(byte[] buf, byte[] target)The method accepts two byte array and returns true if they match.static intparseHeaders(org.apache.axis.transport.http.NonBlockingBufferedInputStream is, byte[] buf, java.lang.StringBuffer contentType, java.lang.StringBuffer contentLocation, java.lang.StringBuffer soapAction, java.lang.StringBuffer httpRequest, java.lang.StringBuffer fileName, java.lang.StringBuffer cookie, java.lang.StringBuffer cookie2, java.lang.StringBuffer authInfo, java.lang.StringBuffer host)Parses headers from the given stream.
-
-
-
Method Detail
-
matches
public static boolean matches(byte[] buf, byte[] target)The method accepts two byte array and returns true if they match. Note: The first array is translated in lower cases and the second one should be in lower cases- Parameters:
buf- byte arraytarget- byte array- Returns:
- boolean
-
matchesCase
public static boolean matchesCase(byte[] buf, byte[] target)The method accepts two byte array and returns true if they match. Note: Case sensitive- Parameters:
buf- byte arraytarget- byte array- Returns:
- boolean
-
matches
public static boolean matches(byte[] buf, int bufIdx, byte[] target)The method accepts two byte array and returns true if the part of the first one starting from position bufIdx matches the second one. Note: The first array is translated in lower cases and the second one should be in lower cases- Parameters:
buf- byte arraybufIdx- int , the position , where the comparison beginstarget- byte array- Returns:
- boolean
-
parseHeaders
public static int parseHeaders(org.apache.axis.transport.http.NonBlockingBufferedInputStream is, byte[] buf, java.lang.StringBuffer contentType, java.lang.StringBuffer contentLocation, java.lang.StringBuffer soapAction, java.lang.StringBuffer httpRequest, java.lang.StringBuffer fileName, java.lang.StringBuffer cookie, java.lang.StringBuffer cookie2, java.lang.StringBuffer authInfo, java.lang.StringBuffer host) throws java.io.IOExceptionParses headers from the given stream.- Parameters:
is-NonBlockingBufferedInputStreambuf- byte arraycontentType-StringBuffercontentLocation-StringBuffersoapAction-StringBufferhttpRequest-StringBufferfileName-StringBuffercookie-StringBuffercookie2-StringBufferauthInfo-StringBufferhost-StringBuffer- Returns:
- int , content length
- Throws:
java.io.IOException
-
-