Package org.apache.ofbiz.webapp.webdav
Class ResponseHelper
java.lang.Object
org.apache.ofbiz.webapp.webdav.ResponseHelper
- Direct Known Subclasses:
PropFindHelper
WebDAV response helper class. This class provides helper methods for
working with WebDAV requests and responses.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreateElementSetValue
(String elementName, String value) Create element set value element.createHrefElement
(String hrefUrl) Create href element element.Create multi status element element.createResponseDescriptionElement
(String description, String lang) Create response description element element.Create response element element.createStatusElement
(String statusText) Create status element element.Gets response document.static void
prepareResponse
(HttpServletResponse response, int statusCode, String statusString) void
writeResponse
(HttpServletResponse response, Writer writer) Write response.
-
Field Details
-
DAV_NAMESPACE_URI
- See Also:
-
STATUS_200
- See Also:
-
STATUS_400
- See Also:
-
STATUS_401
- See Also:
-
STATUS_403
- See Also:
-
STATUS_404
- See Also:
-
-
Constructor Details
-
ResponseHelper
public ResponseHelper()
-
-
Method Details
-
prepareResponse
public static void prepareResponse(HttpServletResponse response, int statusCode, String statusString) -
createElementSetValue
Create element set value element.- Parameters:
elementName
- the element namevalue
- the value- Returns:
- the element
-
createHrefElement
Create href element element.- Parameters:
hrefUrl
- the href url- Returns:
- the element
-
createMultiStatusElement
Create multi status element element.- Returns:
- the element
-
createResponseDescriptionElement
Create response description element element.- Parameters:
description
- the descriptionlang
- the lang- Returns:
- the element
-
createResponseElement
Create response element element.- Returns:
- the element
-
createStatusElement
Create status element element.- Parameters:
statusText
- the status text- Returns:
- the element
-
getResponseDocument
Gets response document.- Returns:
- the response document
-
writeResponse
Write response.- Parameters:
response
- the responsewriter
- the writer- Throws:
IOException
- the io exception
-