|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object m.c.m.proxyma.resource.ProxymaResource
public class ProxymaResource
This class rappresents a resource managed by the proxy.
It countains a request and a response and it has all the attributes required
by the proxyma-core to manage a client request/response.
In other words, this is the object that will be managed by all the plugins.
NOTE: this software is released under GPL License. See the LICENSE of this distribution for more informations.
Constructor Summary | |
---|---|
ProxymaResource(ProxymaRequest request,
ProxymaResponse response,
ProxymaContext context)
Default constructor for this class |
Method Summary | |
---|---|
void |
addAttibute(java.lang.String attributeName,
java.lang.Object attributeValue)
Add a new Attribute to the resource. |
void |
deleteAttribute(java.lang.String anAttributeName)
Remove an attribute from the resource |
java.lang.Object |
getAttribute(java.lang.String anAttributeName)
Get an attribute (if exists) from the resource using its name |
java.util.Collection<java.lang.String> |
getAttributeNames()
Returns a collection of attribute names stored into the resource |
ProxymaContext |
getContext()
Returns the contex where this resource was generated. |
java.lang.String |
getDestinationSubPath()
Returns the subpath relative to the destination of the proxy folder |
ProxyFolderBean |
getProxyFolder()
Returns the proxy foder that matched the requested URI. |
java.net.URL |
getProxymaRootURL()
Returns the URI where proxyma is deployed |
java.lang.String |
getProxymaRootURLAsString()
Returns the complete URI where proxyma is deployed |
ProxymaRequest |
getRequest()
Returns the request generated from the factory method. |
ProxymaResponse |
getResponse()
Returns the response generated from the factory method This the response that will be sent back to the client |
void |
setDestinationSubPath(java.lang.String destinationSubPath)
Sets the subpath relative to the destination of the proxy folder |
void |
setProxyFolder(ProxyFolderBean theFolder)
Set the proxy foder that matched the requested URI. |
void |
setProxymaRootURI(java.lang.String uri)
Sets the complete URI where proxyma is deployed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ProxymaResource(ProxymaRequest request, ProxymaResponse response, ProxymaContext context) throws org.apache.commons.lang.NullArgumentException
context
- the context where the Resource will live.
org.apache.commons.lang.NullArgumentException
- if any of the passed parameters is nullMethod Detail |
---|
public ProxymaContext getContext()
public ProxymaRequest getRequest()
public ProxymaResponse getResponse()
public ProxyFolderBean getProxyFolder()
public java.lang.String getDestinationSubPath()
public void setDestinationSubPath(java.lang.String destinationSubPath)
public java.lang.String getProxymaRootURLAsString()
public java.net.URL getProxymaRootURL()
public void setProxymaRootURI(java.lang.String uri)
public void setProxyFolder(ProxyFolderBean theFolder)
public java.lang.Object getAttribute(java.lang.String anAttributeName)
anAttributeName
- the wanted Resource Attribute
public void addAttibute(java.lang.String attributeName, java.lang.Object attributeValue) throws org.apache.commons.lang.NullArgumentException
attributeName
- the name of the attribute to add.attributeValue
- the value of the attribute, it can be any kind of object so it's a responsability of the reader to do the upper-cast to the proper class.
org.apache.commons.lang.NullArgumentException
- if the attribute name is nullpublic void deleteAttribute(java.lang.String anAttributeName) throws org.apache.commons.lang.NullArgumentException
attributeName
- the attribute to remove.
org.apache.commons.lang.NullArgumentException
- if the argument is nullpublic java.util.Collection<java.lang.String> getAttributeNames()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |