Interface HttpMethods
- All Superinterfaces:
Iterable<HttpMethod>,Streamable<HttpMethod>,Supplier<Stream<HttpMethod>>
- All Known Implementing Classes:
ConfigurableHttpMethods
A collection of
HttpMethods with some convenience methods to create alternate sets of those.- Author:
- Oliver Gierke
-
Method Summary
Modifier and TypeMethodDescriptiondefault HttpMethodsand(HttpMethod... method) Returns a newHttpMethodswith the givenHttpMethods added.default HttpMethodsbutWithout(HttpMethod... method) Returns a newHttpMethodsinstance with the givenHttpMethods removed.booleancontains(HttpMethod method) Returns whether the givenHttpMethodis contained in the currentHttpMethods.static HttpMethodsnone()static HttpMethodsof(Collection<HttpMethod> methods) Returns a newHttpMethodswith the givenHttpMethods.default Set<HttpMethod>toSet()Returns an unmodifiableSetof all underlyingHttpMethods.Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
Method Details
-
none
-
of
Returns a newHttpMethodswith the givenHttpMethods.- Parameters:
methods- must not be null.- Returns:
-
contains
Returns whether the givenHttpMethodis contained in the currentHttpMethods.- Parameters:
method- must not be null.- Returns:
-
toSet
Returns an unmodifiableSetof all underlyingHttpMethods.- Specified by:
toSetin interfaceStreamable<HttpMethod>- Returns:
-
and
Returns a newHttpMethodswith the givenHttpMethods added.- Specified by:
andin interfaceStreamable<HttpMethod>- Parameters:
method- must not be null.- Returns:
-
butWithout
Returns a newHttpMethodsinstance with the givenHttpMethods removed.- Parameters:
method- must not be null.- Returns:
-