Top Description Inners Constructors Methods
org.springframework.web.reactive.result.method.annotation

public Class MatrixVariableMethodArgumentResolver

extends AbstractNamedValueSyncArgumentResolver
Class Inheritance
Imports
java.util.ArrayList, .List, .Map, org.springframework.beans.factory.config.ConfigurableBeanFactory, org.springframework.core.MethodParameter, .ReactiveAdapterRegistry, org.springframework.lang.Nullable, org.springframework.util.Assert, .CollectionUtils, .MultiValueMap, .StringUtils, org.springframework.web.bind.annotation.MatrixVariable, .ValueConstants, org.springframework.web.reactive.HandlerMapping, org.springframework.web.server.MissingRequestValueException, .ServerErrorException, .ServerWebExchange, .ServerWebInputException

Resolves arguments annotated with @MatrixVariable.

If the method parameter is of type Map it will be resolved by MatrixVariableMapMethodArgumentResolver instead unless the annotation specifies a name in which case it is considered to be a single attribute of type map (vs multiple attributes collected in a map).

Author
Rossen Stoyanchev
Since
5.0.1
See Also
MatrixVariableMapMethodArgumentResolver

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected AbstractNamedValueArgumentResolver.NamedValueInfo
protected void
handleMissingValue(String
the name for the value
name
,
MethodParameter
the method parameter
parameter
)

Overrides org.springframework.web.reactive.result.method.annotation.AbstractNamedValueArgumentResolver.handleMissingValue.

Invoked when a named value is required, but resolveName(String, MethodParameter, ServerWebExchange) returned null and there is no default value.

protected Object
public boolean
supportsParameter(MethodParameter
the method parameter
parameter
)

Implements org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver.supportsParameter.

Whether this resolver supports the given method parameter.

Inherited from org.springframework.web.reactive.result.method.annotation.AbstractNamedValueSyncArgumentResolver:
resolveArgumentresolveArgumentValueresolveName

Constructor Detail

MatrixVariableMethodArgumentResolverback to summary
public MatrixVariableMethodArgumentResolver(ConfigurableBeanFactory factory, ReactiveAdapterRegistry registry)

Method Detail

createNamedValueInfoback to summary
protected AbstractNamedValueArgumentResolver.NamedValueInfo createNamedValueInfo(MethodParameter parameter)

Implements abstract org.springframework.web.reactive.result.method.annotation.AbstractNamedValueArgumentResolver.createNamedValueInfo.

Doc from org.springframework.web.reactive.result.method.annotation.AbstractNamedValueArgumentResolver.createNamedValueInfo.

Create the NamedValueInfo object for the given method parameter. Implementations typically retrieve the method annotation by means of MethodParameter#getParameterAnnotation(Class).

Parameters
parameter:MethodParameter

the method parameter

Returns:AbstractNamedValueArgumentResolver.NamedValueInfo

the named value information

Annotations
@Override
handleMissingValueback to summary
protected void handleMissingValue(String name, MethodParameter parameter) throws ServerWebInputException

Overrides org.springframework.web.reactive.result.method.annotation.AbstractNamedValueArgumentResolver.handleMissingValue.

Doc from org.springframework.web.reactive.result.method.annotation.AbstractNamedValueArgumentResolver.handleMissingValue.

Invoked when a named value is required, but resolveName(String, MethodParameter, ServerWebExchange) returned null and there is no default value. Subclasses typically throw an exception in this case.

Parameters
name:String

the name for the value

parameter:MethodParameter

the method parameter

Annotations
@Override
resolveNamedValueback to summary
protected Object resolveNamedValue(String name, MethodParameter param, ServerWebExchange exchange)

Implements abstract org.springframework.web.reactive.result.method.annotation.AbstractNamedValueSyncArgumentResolver.resolveNamedValue.

Doc from org.springframework.web.reactive.result.method.annotation.AbstractNamedValueSyncArgumentResolver.resolveNamedValue.

Actually resolve the value synchronously.

Annotations
@Nullable
@Override
supportsParameterback to summary
public boolean supportsParameter(MethodParameter parameter)

Implements org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver.supportsParameter.

Doc from org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver.supportsParameter.

Whether this resolver supports the given method parameter.

Parameters
parameter:MethodParameter

the method parameter

Annotations
@Override
org.springframework.web.reactive.result.method.annotation back to summary

private final Class MatrixVariableMethodArgumentResolver.MatrixVariableNamedValueInfo

extends NamedValueInfo
Class Inheritance

Constructor Summary

AccessConstructor and Description
private

Constructor Detail

MatrixVariableNamedValueInfoback to summary
private MatrixVariableNamedValueInfo(MatrixVariable annotation)