Package akka.http.scaladsl.server
Interface ImplicitPathMatcherConstruction
-
- All Known Subinterfaces:
Directives,PathDirectives
- All Known Implementing Classes:
Directives$,HttpApp,PathDirectives$,PathMatcher$
public interface ImplicitPathMatcherConstruction
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description PathMatcher<scala.Tuple1<java.lang.String>>_regex2PathMatcher(scala.util.matching.Regex regex)Creates a PathMatcher that consumes (a prefix of) the first path segment if the path begins with a segment (a prefix of) which matches the given regex.PathMatcher<scala.runtime.BoxedUnit>_segmentStringToPathMatcher(java.lang.String segment)Creates a PathMatcher that consumes (a prefix of) the first path segment (if the path begins with a segment).<T> PathMatcher<scala.Tuple1<T>>_stringExtractionPair2PathMatcher(scala.Tuple2<java.lang.String,T> tuple)Creates a PathMatcher that consumes (a prefix of) the first path segment (if the path begins with a segment) and extracts a given value.PathMatcher<scala.runtime.BoxedUnit>_stringNameOptionReceptacle2PathMatcher(NameOptionReceptacle<java.lang.String> nr)<T> PathMatcher<scala.Tuple1<T>>_valueMap2PathMatcher(scala.collection.immutable.Map<java.lang.String,T> valueMap)Creates a PathMatcher from the given Map of path segments (prefixes) to extracted values.
-
-
-
Method Detail
-
_regex2PathMatcher
PathMatcher<scala.Tuple1<java.lang.String>> _regex2PathMatcher(scala.util.matching.Regex regex)
Creates a PathMatcher that consumes (a prefix of) the first path segment if the path begins with a segment (a prefix of) which matches the given regex. Extracts either the complete match (if the regex doesn't contain a capture group) or the capture group (if the regex contains exactly one). If the regex contains more than one capture group the method throws an IllegalArgumentException.- Parameters:
regex- (undocumented)- Returns:
- (undocumented)
-
_segmentStringToPathMatcher
PathMatcher<scala.runtime.BoxedUnit> _segmentStringToPathMatcher(java.lang.String segment)
Creates a PathMatcher that consumes (a prefix of) the first path segment (if the path begins with a segment).- Parameters:
segment- (undocumented)- Returns:
- (undocumented)
-
_stringExtractionPair2PathMatcher
<T> PathMatcher<scala.Tuple1<T>> _stringExtractionPair2PathMatcher(scala.Tuple2<java.lang.String,T> tuple)
Creates a PathMatcher that consumes (a prefix of) the first path segment (if the path begins with a segment) and extracts a given value.- Parameters:
tuple- (undocumented)- Returns:
- (undocumented)
-
_stringNameOptionReceptacle2PathMatcher
PathMatcher<scala.runtime.BoxedUnit> _stringNameOptionReceptacle2PathMatcher(NameOptionReceptacle<java.lang.String> nr)
- Parameters:
nr- (undocumented)- Returns:
- (undocumented)
-
_valueMap2PathMatcher
<T> PathMatcher<scala.Tuple1<T>> _valueMap2PathMatcher(scala.collection.immutable.Map<java.lang.String,T> valueMap)
Creates a PathMatcher from the given Map of path segments (prefixes) to extracted values. If the unmatched path starts with a segment having one of the maps keys as a prefix the matcher consumes this path segment (prefix) and extracts the corresponding map value. For keys sharing a common prefix the longest matching prefix is selected.- Parameters:
valueMap- (undocumented)- Returns:
- (undocumented)
-
-