|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthelma.framework.core.RequestPath
public class RequestPath
Represents a URI request path that has been resolved to an object path. Offers methods to access objects in the path by index and prototype names, and to render the path as URI again.
Constructor Summary | |
---|---|
RequestPath(Application app)
Creates a new RequestPath object. |
Method Summary | |
---|---|
void |
add(java.lang.String id,
java.lang.Object obj)
Adds an item to the end of the path. |
int |
contains(java.lang.Object obj)
Deprecated. use indexOf(Object) instead. |
java.lang.Object |
get(int idx)
Gets an object in the path by index. |
java.lang.Object |
getByPrototypeName(java.lang.String typeName)
Gets an object in the path by prototype name. |
java.lang.String |
href(java.lang.String action)
Returns the string representation of this path usable for links. |
int |
indexOf(java.lang.Object obj)
Checks if the given object is contained in the request path. |
int |
size()
Returns the number of objects in the request path. |
java.lang.String |
toString()
Return a string representation of the Request Path |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public RequestPath(Application app)
app
- the application we're running inMethod Detail |
---|
public void add(java.lang.String id, java.lang.Object obj)
id
- the item id representing the path in the URLobj
- the object to which the id resolvespublic int size()
public java.lang.Object get(int idx)
idx
- the index of the object in the request pathpublic java.lang.Object getByPrototypeName(java.lang.String typeName)
typeName
- the prototype name of the object in the request pathpublic java.lang.String href(java.lang.String action) throws java.io.UnsupportedEncodingException
java.io.UnsupportedEncodingException
public int contains(java.lang.Object obj)
indexOf(Object)
instead.
obj
- the element to check
public int indexOf(java.lang.Object obj)
obj
- the element to check
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |