Class HttpContent
- java.lang.Object
-
- de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.batch.Request
-
- de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.multipart.HttpContent
-
- All Implemented Interfaces:
Content,MultipartContent
public class HttpContent extends Request implements MultipartContent
- Author:
- scf
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.multipart.MultipartContent
MultipartContent.IsFinished
-
-
Field Summary
-
Fields inherited from class de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.batch.Request
batchVersion, contentId, contentIdValue, data, errors, executeFailed, headersInner, headersOuter, logIndent, method, parseFailed, path, requireContentId, version
-
-
Constructor Summary
Constructors Constructor Description HttpContent(de.fraunhofer.iosb.ilt.frostserver.path.Version batchVersion)HttpContent(de.fraunhofer.iosb.ilt.frostserver.path.Version batchVersion, boolean requireContentId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetContent(boolean allHeaders)Get the String content for response.StringgetStatusLine()MultipartContent.IsFinishedisFinished()Gives the parse-state of the Content.voidparseLine(String line)Add the line to the content.voidsetStatus(int code, String text)voidsetStatusLine(String statusLine)voidstripLastNewline()Informs the Content that the last newline should be removed again.-
Methods inherited from class de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.batch.Request
addData, getContentId, getContentIdValue, getData, getErrors, getHeaders, getHttpHeaders, getMethod, getPath, getVersion, isExecuteFailed, isParseFailed, parseUrl, setContentId, setContentIdValue, setExecuteFailed, setLogIndent, setMethod, setPath, updateUsingContentIds
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.fraunhofer.iosb.ilt.frostserver.plugin.batchprocessing.batch.Content
getErrors, getHeaders, isParseFailed, setLogIndent
-
-
-
-
Method Detail
-
parseLine
public void parseLine(String line)
Description copied from interface:MultipartContentAdd the line to the content.- Specified by:
parseLinein interfaceMultipartContent- Parameters:
line- The line to add.
-
getStatusLine
public String getStatusLine()
-
setStatusLine
public void setStatusLine(String statusLine)
-
getContent
public String getContent(boolean allHeaders)
Description copied from interface:ContentGet the String content for response.- Specified by:
getContentin interfaceContent- Parameters:
allHeaders- flag indicating all headers should be included. If the content is going to be added to a HttpServletResponse, the headers need to be set separately.- Returns:
- The content.
-
stripLastNewline
public void stripLastNewline()
Description copied from interface:MultipartContentInforms the Content that the last newline should be removed again. The newline before a boundary is part of the boundary, not of the content.- Specified by:
stripLastNewlinein interfaceMultipartContent
-
isFinished
public MultipartContent.IsFinished isFinished()
Description copied from interface:MultipartContentGives the parse-state of the Content. This indicates if more content is expected or not.- Specified by:
isFinishedin interfaceMultipartContent- Returns:
- the parse-state of the Content.
-
-