Class PathMappings<E>
java.lang.Object
org.eclipse.jetty.http.pathmap.PathMappings<E>
- Type Parameters:
E- the type of mapping endpoint
- All Implemented Interfaces:
Iterable<MappedResource<E>>, Dumpable
@ManagedObject("Path Mappings")
public class PathMappings<E>
extends Object
implements Iterable<MappedResource<E>>, Dumpable
Path Mappings of PathSpec to Resource.
Sorted into search order upon entry into the Set
-
Nested Class Summary
Nested classes/interfaces inherited from interface Dumpable
Dumpable.DumpableContainer -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Trie<MappedResource<E>> private final Set<MappedResource<E>> private booleanprivate booleanprivate booleanprivate Trie<MappedResource<E>> private Trie<MappedResource<E>> private static final Logger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic PathSpecasPathSpec(String pathSpecString) Deprecated.private booleancanBeOptimized(PathSpecGroup suffixGlob) dump()voiddump(Appendable out, String indent) Dump this object (and children) into an Appendable using the provided indent after any new lines.Deprecated.usegetMatched(String)insteadgetMatched(String path) getMatchedList(String path) Return a list of MatchedResource matches for the specified path.getMatches(String path) Return a list of MappedResource matches for the specified path.iterator()booleanbooleanbooleanvoidremoveIf(Predicate<MappedResource<E>> predicate) voidreset()intsize()toString()Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Field Details
-
LOG
-
_mappings
-
_optimizedExact
private boolean _optimizedExact -
_exactMap
-
_optimizedPrefix
private boolean _optimizedPrefix -
_prefixMap
-
_optimizedSuffix
private boolean _optimizedSuffix -
_suffixMap
-
-
Constructor Details
-
PathMappings
public PathMappings()
-
-
Method Details
-
dump
-
dump
Description copied from interface:DumpableDump this object (and children) into an Appendable using the provided indent after any new lines. The indent should not be applied to the first object dumped.- Specified by:
dumpin interfaceDumpable- Parameters:
out- The appendable to dump toindent- The indent to apply after any new lines.- Throws:
IOException- if unable to write to Appendable
-
getMappings
-
size
public int size() -
reset
public void reset() -
removeIf
-
getMatchedList
Return a list of MatchedResource matches for the specified path.- Parameters:
path- the path to return matches on- Returns:
- the list of mapped resource the path matches on
-
getMatches
Return a list of MappedResource matches for the specified path.- Parameters:
path- the path to return matches on- Returns:
- the list of mapped resource the path matches on
-
getMatched
-
getMatch
Deprecated.usegetMatched(String)instead -
iterator
-
asPathSpec
Deprecated.usePathSpec.from(String)instead -
get
-
put
-
put
-
remove
-
canBeOptimized
-
toString
-
PathSpec.from(String)instead