AuthMatcher class abstract

Matchers to include or exclude urls from authentication

NOTE: do NOT throw in matchers

note: method is always in upper case

Constructors

AuthMatcher.all()
always match
const
factory
AuthMatcher.baseUrl(String baseUrl)
base url matching
const
factory
AuthMatcher.baseUrls(Set<String> baseUrls)
base urls matching
const
factory
AuthMatcher.byMethod(bool matchMethod(String method))
provide lambda for method
const
factory
AuthMatcher.byMethodAndUrl(bool match(String method, String url))
provide lambda for method and url
const
factory
AuthMatcher.byUrl(bool matchUrl(String url))
provide lambda for url
const
factory
AuthMatcher.general(bool lambda(RequestOptions request))
general matcher
const
factory
AuthMatcher.intersectionOf(List<AuthMatcher> matchers)
intersection of matchers
const
factory
AuthMatcher.method(Pattern methodPattern)
provide regex or string to match exactly
const
factory
AuthMatcher.methodAndBaseUrl(Pattern methodPattern, String baseUrl)
method and base url
factory
AuthMatcher.methodAndUrl(Pattern methodPattern, Pattern urlPattern)
method and url
const
factory
AuthMatcher.methods(Set<Pattern> methodPatterns)
provide regex or string to match exactly
const
factory
AuthMatcher.none()
never match
const
factory
AuthMatcher.unionOf(List<AuthMatcher> matchers)
union of matchers
const
factory
AuthMatcher.url(Pattern urlPattern)
provide regex or string to match exactly
const
factory
AuthMatcher.urls(Set<Pattern> urlPatterns)
provide regex or string to match exactly
const
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

matchesRequest(RequestOptions request) bool
check if matches request
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator &(AuthMatcher other) AuthMatcher
intersection
operator -(AuthMatcher other) AuthMatcher
difference
operator ==(Object other) bool
The equality operator.
inherited
operator ^(AuthMatcher other) AuthMatcher
symmetric difference
operator unary-() AuthMatcher
negate
operator |(AuthMatcher other) AuthMatcher
union