public final class ResourcePath extends Object
Constructor and Description |
---|
ResourcePath(String resourcePath)
Constructs a new
ResourcePath . |
ResourcePath(String resourcePath,
javax.ws.rs.core.HttpHeaders httpHeaders)
Constructs a new
ResourcePath with an additional
QueryParameter map. |
ResourcePath(String resourcePath,
Map<QueryParameter,String> queryParameters)
Constructs a new
ResourcePath with an additional
QueryParameter map. |
ResourcePath(String resourcePath,
Map<QueryParameter,String> queryParameters,
javax.ws.rs.core.HttpHeaders httpHeaders)
Constructs a new
ResourcePath with an additional
QueryParameter map. |
Modifier and Type | Method and Description |
---|---|
int |
getDepth()
Returns the depth of the resource path.
|
javax.ws.rs.core.HttpHeaders |
getHttpHeaders()
Return HTTP headers from user request.
|
Map<QueryParameter,String> |
getQueryParameter()
This map return all available query parameters.
|
String |
getResource(int level)
Returns the resource at the specified level.
|
String |
getResourcePath()
Returns the complete resource path string.
|
String |
getValue(QueryParameter key)
Returns the value of the specified query parameter, or
null if no
value is mapped. |
String |
toString() |
public ResourcePath(String resourcePath)
ResourcePath
.resourcePath
- resource path stringpublic ResourcePath(String resourcePath, Map<QueryParameter,String> queryParameters)
ResourcePath
with an additional
QueryParameter
map.resourcePath
- resource path stringqueryParameters
- query parameterspublic ResourcePath(String resourcePath, javax.ws.rs.core.HttpHeaders httpHeaders)
ResourcePath
with an additional
QueryParameter
map.resourcePath
- resource path stringhttpHeaders
- HTTP header attributes.public ResourcePath(String resourcePath, Map<QueryParameter,String> queryParameters, javax.ws.rs.core.HttpHeaders httpHeaders)
ResourcePath
with an additional
QueryParameter
map.resourcePath
- resource path stringqueryParameters
- query parametershttpHeaders
- HTTP header attributes.public String getResourcePath()
public String getResource(int level)
level
- resource levelpublic int getDepth()
public String getValue(QueryParameter key)
null
if no
value is mapped.key
- query keypublic Map<QueryParameter,String> getQueryParameter()
public javax.ws.rs.core.HttpHeaders getHttpHeaders()
Copyright © 2013. All Rights Reserved.