Package com.enonic.xp.content
Class ContentPath
- java.lang.Object
-
- com.enonic.xp.content.ContentPath
-
@PublicApi public final class ContentPath extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ContentPath.Builder
-
Field Summary
Fields Modifier and Type Field Description static ContentPath
ROOT
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ContentPath
asAbsolute()
ContentPath
asRelative()
int
compareTo(ContentPath contentPath)
static ContentPath.Builder
create()
int
elementCount()
boolean
equals(Object o)
static ContentPath
from(ContentPath parent, ContentPath relative)
static ContentPath
from(ContentPath parent, String name)
static ContentPath
from(String path)
ContentPath
getAncestorPath(int deep)
String
getElement(int index)
String
getName()
ContentPath
getParentPath()
int
hashCode()
boolean
hasName()
boolean
isAbsolute()
boolean
isChildOf(ContentPath possibleParentPath)
boolean
isRelative()
boolean
isRoot()
String
toString()
-
-
-
Field Detail
-
ROOT
public static final ContentPath ROOT
-
-
Method Detail
-
getElement
public String getElement(int index)
-
isRoot
public boolean isRoot()
-
elementCount
public int elementCount()
-
getParentPath
public ContentPath getParentPath()
-
getAncestorPath
public ContentPath getAncestorPath(int deep)
-
isAbsolute
public boolean isAbsolute()
-
isRelative
public boolean isRelative()
-
asRelative
public ContentPath asRelative()
-
asAbsolute
public ContentPath asAbsolute()
-
hasName
public boolean hasName()
-
getName
public String getName()
-
isChildOf
public boolean isChildOf(ContentPath possibleParentPath)
-
compareTo
public int compareTo(ContentPath contentPath)
-
from
public static ContentPath from(String path)
-
from
public static ContentPath from(ContentPath parent, String name)
-
from
public static ContentPath from(ContentPath parent, ContentPath relative)
-
create
public static ContentPath.Builder create()
-
-