Class HtmlResponseProxy
- java.lang.Object
-
- org.apache.sling.api.servlets.HtmlResponse
-
- org.apache.sling.servlets.post.impl.helper.HtmlResponseProxy
-
public class HtmlResponseProxy extends org.apache.sling.api.servlets.HtmlResponseTheHtmlResponseProxyextends the Sling APIHtmlResponseoverwriting all public methods and redirecting to a proxiedPostResponse. As a consequence the underlying (extended) Sling APIHtmlResponsewill not be fed with data and thus will remain "empty".This class is mainly used by the deprecated
AbstractSlingPostOperationfor bridging into the newAbstractPostOperation.
-
-
Constructor Summary
Constructors Constructor Description HtmlResponseProxy(PostResponse postResponse)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ThrowablegetError()StringgetLocation()StringgetParentLocation()StringgetPath()PostResponsegetPostResponse()ObjectgetProperty(String name)<Type> TypegetProperty(String name, Class<Type> type)StringgetReferer()intgetStatusCode()StringgetStatusMessage()booleanisCreateRequest()booleanisSuccessful()voidonChange(String type, String... arguments)voidonCopied(String srcPath, String dstPath)voidonCreated(String path)voidonDeleted(String path)voidonModified(String path)voidonMoved(String srcPath, String dstPath)voidsend(javax.servlet.http.HttpServletResponse response, boolean setStatus)voidsetCreateRequest(boolean isCreateRequest)voidsetError(Throwable error)voidsetLocation(String location)voidsetParentLocation(String parentLocation)voidsetPath(String path)voidsetProperty(String name, Object value)voidsetReferer(String referer)voidsetStatus(int code, String message)voidsetTitle(String title)
-
-
-
Constructor Detail
-
HtmlResponseProxy
public HtmlResponseProxy(PostResponse postResponse)
-
-
Method Detail
-
getPostResponse
public PostResponse getPostResponse()
-
getProperty
public <Type> Type getProperty(String name, Class<Type> type)
- Overrides:
getPropertyin classorg.apache.sling.api.servlets.HtmlResponse
-
getProperty
public Object getProperty(String name)
- Overrides:
getPropertyin classorg.apache.sling.api.servlets.HtmlResponse
-
setProperty
public void setProperty(String name, Object value)
- Overrides:
setPropertyin classorg.apache.sling.api.servlets.HtmlResponse
-
getError
public Throwable getError()
- Overrides:
getErrorin classorg.apache.sling.api.servlets.HtmlResponse
-
getLocation
public String getLocation()
- Overrides:
getLocationin classorg.apache.sling.api.servlets.HtmlResponse
-
getParentLocation
public String getParentLocation()
- Overrides:
getParentLocationin classorg.apache.sling.api.servlets.HtmlResponse
-
getPath
public String getPath()
- Overrides:
getPathin classorg.apache.sling.api.servlets.HtmlResponse
-
getReferer
public String getReferer()
- Overrides:
getRefererin classorg.apache.sling.api.servlets.HtmlResponse
-
getStatusCode
public int getStatusCode()
- Overrides:
getStatusCodein classorg.apache.sling.api.servlets.HtmlResponse
-
getStatusMessage
public String getStatusMessage()
- Overrides:
getStatusMessagein classorg.apache.sling.api.servlets.HtmlResponse
-
isCreateRequest
public boolean isCreateRequest()
- Overrides:
isCreateRequestin classorg.apache.sling.api.servlets.HtmlResponse
-
isSuccessful
public boolean isSuccessful()
- Overrides:
isSuccessfulin classorg.apache.sling.api.servlets.HtmlResponse
-
onChange
public void onChange(String type, String... arguments)
- Overrides:
onChangein classorg.apache.sling.api.servlets.HtmlResponse
-
onCopied
public void onCopied(String srcPath, String dstPath)
- Overrides:
onCopiedin classorg.apache.sling.api.servlets.HtmlResponse
-
onCreated
public void onCreated(String path)
- Overrides:
onCreatedin classorg.apache.sling.api.servlets.HtmlResponse
-
onDeleted
public void onDeleted(String path)
- Overrides:
onDeletedin classorg.apache.sling.api.servlets.HtmlResponse
-
onModified
public void onModified(String path)
- Overrides:
onModifiedin classorg.apache.sling.api.servlets.HtmlResponse
-
onMoved
public void onMoved(String srcPath, String dstPath)
- Overrides:
onMovedin classorg.apache.sling.api.servlets.HtmlResponse
-
send
public void send(javax.servlet.http.HttpServletResponse response, boolean setStatus) throws IOException- Overrides:
sendin classorg.apache.sling.api.servlets.HtmlResponse- Throws:
IOException
-
setCreateRequest
public void setCreateRequest(boolean isCreateRequest)
- Overrides:
setCreateRequestin classorg.apache.sling.api.servlets.HtmlResponse
-
setError
public void setError(Throwable error)
- Overrides:
setErrorin classorg.apache.sling.api.servlets.HtmlResponse
-
setLocation
public void setLocation(String location)
- Overrides:
setLocationin classorg.apache.sling.api.servlets.HtmlResponse
-
setParentLocation
public void setParentLocation(String parentLocation)
- Overrides:
setParentLocationin classorg.apache.sling.api.servlets.HtmlResponse
-
setPath
public void setPath(String path)
- Overrides:
setPathin classorg.apache.sling.api.servlets.HtmlResponse
-
setReferer
public void setReferer(String referer)
- Overrides:
setRefererin classorg.apache.sling.api.servlets.HtmlResponse
-
setStatus
public void setStatus(int code, String message)- Overrides:
setStatusin classorg.apache.sling.api.servlets.HtmlResponse
-
setTitle
public void setTitle(String title)
- Overrides:
setTitlein classorg.apache.sling.api.servlets.HtmlResponse
-
-