Package org.aksw.commons.path.core
Class PathOpsStr
java.lang.Object
org.aksw.commons.path.core.PathOpsStr
- All Implemented Interfaces:
Serializable,PathOps<String,PathStr>
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionMethod to create a string from an argument of type T.protected StringescapeSegment(String str) fromString(String str) Deserialize a string into a pathstatic PathOpsStrget()The path segment to navigate to the parent, such as '..'To token for a path to refer to itself, such as '.'Create a new absolute or relative path based on the given segmentsSerialize a path as a stringtoStringRaw(Object path) protected StringunescapeSegment(String str) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.aksw.commons.path.core.PathOps
newAbsolutePath, newAbsolutePath, newAbsolutePath, newRelativePath, newRelativePath, newRelativePath
-
Constructor Details
-
PathOpsStr
public PathOpsStr()
-
-
Method Details
-
get
-
create
Description copied from interface:PathOpsMethod to create a string from an argument of type T. In most other cases, this method should return a relative path with the argument as the only segment. However, if T isString(-like) then this method should parse the argument into an appropriate path. Implementations ofPath.resolve(Object)should rely on this method. -
upcast
-
getBasePathSegments
- Specified by:
getBasePathSegmentsin interfacePathOps<String,PathStr>
-
getComparator
- Specified by:
getComparatorin interfacePathOps<String,PathStr>
-
newPath
Description copied from interface:PathOpsCreate a new absolute or relative path based on the given segments -
getSelfToken
Description copied from interface:PathOpsTo token for a path to refer to itself, such as '.'- Specified by:
getSelfTokenin interfacePathOps<String,PathStr>
-
getParentToken
Description copied from interface:PathOpsThe path segment to navigate to the parent, such as '..'- Specified by:
getParentTokenin interfacePathOps<String,PathStr>
-
escapeSegment
-
unescapeSegment
-
toStringRaw
- Specified by:
toStringRawin interfacePathOps<String,PathStr>
-
toString
Description copied from interface:PathOpsSerialize a path as a string -
fromString
Description copied from interface:PathOpsDeserialize a string into a path- Specified by:
fromStringin interfacePathOps<String,PathStr>
-