public interface PathSpec extends java.lang.Comparable<PathSpec>
Implementors must override Object.equals(Object)
and Object.hashCode()
.
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getDeclaration()
The as-provided path spec.
|
PathSpecGroup |
getGroup()
The spec group.
|
int |
getPathDepth()
Get the number of path elements that this path spec declares.
|
java.lang.String |
getPathInfo(java.lang.String path)
Return the portion of the path that is after the path spec.
|
java.lang.String |
getPathMatch(java.lang.String path)
Return the portion of the path that matches a path spec.
|
java.lang.String |
getPrefix()
A simple prefix match for the pathspec or null
|
int |
getSpecLength()
The length of the spec.
|
java.lang.String |
getSuffix()
A simple suffix match for the pathspec or null
|
boolean |
matches(java.lang.String path)
Test to see if the provided path matches this path spec
|
int getSpecLength()
PathSpecGroup getGroup()
int getPathDepth()
This is used to determine longest match logic.
java.lang.String getPathInfo(java.lang.String path)
path
- the path to match againstjava.lang.String getPathMatch(java.lang.String path)
path
- the path to match againstjava.lang.String getDeclaration()
java.lang.String getPrefix()
java.lang.String getSuffix()
boolean matches(java.lang.String path)
path
- the path to testCopyright © 1995–2021 Webtide. All rights reserved.