Class URIPath
- java.lang.Object
-
- co.arago.hiro.client.util.httpclient.URIPath
-
public class URIPath extends java.lang.ObjectSimple builder class for URI paths.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.LinkedList<java.lang.String>path
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description URIPathappend(java.lang.String... pathParts)URIPathappend(java.util.List<java.lang.String> pathParts)java.lang.Stringbuild()Create a valid escaped path string.URIPathclear()URIPathprepend(java.lang.String... pathParts)URIPathprepend(java.util.List<java.lang.String> pathParts)
-
-
-
Method Detail
-
clear
public URIPath clear()
-
append
public URIPath append(java.util.List<java.lang.String> pathParts)
- Parameters:
pathParts- Path fragments to add to the back of the path.- Returns:
- this
-
append
public URIPath append(java.lang.String... pathParts)
- Parameters:
pathParts- Path fragments to add to the back of the path.- Returns:
- this
-
prepend
public URIPath prepend(java.util.List<java.lang.String> pathParts)
- Parameters:
pathParts- Path fragments to add to the front of the path.- Returns:
- this
-
prepend
public URIPath prepend(java.lang.String... pathParts)
- Parameters:
pathParts- Path fragments to add to the front of the path.- Returns:
- this
-
build
public java.lang.String build()
Create a valid escaped path string.- Returns:
- The encoded path without a leading '/'.
-
-