Add "result" package under ~.web.reactive

The new package is parallel to the "mvc" package under spring-webmvc
and a place to hold the various programming model styles.
This commit is contained in:
Rossen Stoyanchev 2016-04-14 15:56:53 -04:00
parent 3460e577ad
commit 341f23e0e6
26 changed files with 45 additions and 134 deletions

View File

@ -1,19 +1,3 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Core package of the reactive client HTTP support.
* Provides {@link org.springframework.http.client.reactive.ClientHttpRequest}

View File

@ -1,20 +1,5 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Provides reactive HandlerMapping implementations.
* Provides standard HandlerMapping implementations,
* including abstract base classes for custom implementations.
*/
package org.springframework.web.reactive.handler;

View File

@ -1,20 +0,0 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Reactive infrastructure for annotation-based handler method processing.
*/
package org.springframework.web.reactive.method.annotation;

View File

@ -1,20 +0,0 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Reactive infrastructure for handler method processing.
*/
package org.springframework.web.reactive.method;

View File

@ -1,20 +1,4 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Provides the core interfaces and classes for the Spring web reactive framework.
* Core interfaces and classes for Spring Web Reactive.
*/
package org.springframework.web.reactive;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.handler;
package org.springframework.web.reactive.result;
import java.util.Optional;

View File

@ -14,14 +14,12 @@
* limitations under the License.
*/
package org.springframework.web.reactive.handler;
package org.springframework.web.reactive.result;
import org.reactivestreams.Publisher;
import reactor.core.publisher.Mono;
import org.springframework.core.ResolvableType;
import org.springframework.ui.ExtendedModelMap;
import org.springframework.ui.ModelMap;
import org.springframework.web.reactive.DispatcherHandler;
import org.springframework.web.reactive.HandlerAdapter;
import org.springframework.web.reactive.HandlerResult;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method;
package org.springframework.web.reactive.result.method;
import reactor.core.publisher.Mono;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method;
package org.springframework.web.reactive.result.method;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;

View File

@ -13,14 +13,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import reactor.core.publisher.Mono;
import org.springframework.core.MethodParameter;
import org.springframework.ui.Model;
import org.springframework.ui.ModelMap;
import org.springframework.web.reactive.method.HandlerMethodArgumentResolver;
import org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver;
import org.springframework.web.server.ServerWebExchange;
/**

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.util.List;
@ -31,7 +31,7 @@ import org.springframework.http.MediaType;
import org.springframework.ui.ModelMap;
import org.springframework.util.Assert;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.reactive.method.HandlerMethodArgumentResolver;
import org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver;
import org.springframework.web.server.ServerWebExchange;
/**

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.lang.reflect.Method;
import java.util.ArrayList;
@ -45,8 +45,8 @@ import org.springframework.web.method.HandlerMethod;
import org.springframework.web.method.annotation.ExceptionHandlerMethodResolver;
import org.springframework.web.reactive.HandlerAdapter;
import org.springframework.web.reactive.HandlerResult;
import org.springframework.web.reactive.method.HandlerMethodArgumentResolver;
import org.springframework.web.reactive.method.InvocableHandlerMethod;
import org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver;
import org.springframework.web.reactive.result.method.InvocableHandlerMethod;
import org.springframework.web.server.ServerWebExchange;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.util.Arrays;
import java.util.Collection;

View File

@ -14,14 +14,14 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import reactor.core.publisher.Mono;
import org.springframework.core.MethodParameter;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.reactive.method.HandlerMethodArgumentResolver;
import org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.util.UriComponents;
import org.springframework.web.util.UriComponentsBuilder;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.util.ArrayList;
import java.util.Collections;

View File

@ -0,0 +1,4 @@
/**
* Infrastructure for annotation-based handler method processing.
*/
package org.springframework.web.reactive.result.method.annotation;

View File

@ -0,0 +1,4 @@
/**
* Infrastructure for handler method processing.
*/
package org.springframework.web.reactive.result.method;

View File

@ -0,0 +1,4 @@
/**
* Provides various controller styles for request handling.
*/
package org.springframework.web.reactive.result;

View File

@ -1,18 +1,2 @@
/*
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@javax.xml.bind.annotation.XmlSchema(namespace = "namespace")
package org.springframework.core.codec.support.jaxb;

View File

@ -46,9 +46,9 @@ import org.springframework.web.ResponseStatusException;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.reactive.method.annotation.RequestMappingHandlerAdapter;
import org.springframework.web.reactive.method.annotation.RequestMappingHandlerMapping;
import org.springframework.web.reactive.method.annotation.ResponseBodyResultHandler;
import org.springframework.web.reactive.result.method.annotation.RequestMappingHandlerAdapter;
import org.springframework.web.reactive.result.method.annotation.RequestMappingHandlerMapping;
import org.springframework.web.reactive.result.method.annotation.ResponseBodyResultHandler;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.WebExceptionHandler;
import org.springframework.web.server.WebFilter;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.handler;
package org.springframework.web.reactive.result;
import java.util.concurrent.CompletableFuture;
@ -29,6 +29,7 @@ import org.springframework.core.convert.support.ReactiveStreamsToCompletableFutu
import org.springframework.core.convert.support.ReactiveStreamsToRxJava1Converter;
import org.springframework.web.method.HandlerMethod;
import org.springframework.web.reactive.HandlerResult;
import org.springframework.web.reactive.result.SimpleResultHandler;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.handler;
package org.springframework.web.reactive.result;
import java.net.URI;
import java.nio.charset.Charset;
@ -38,6 +38,9 @@ import org.springframework.web.client.HttpClientErrorException;
import org.springframework.web.client.RestTemplate;
import org.springframework.web.reactive.DispatcherHandler;
import org.springframework.web.reactive.ResponseStatusExceptionHandler;
import org.springframework.web.reactive.handler.SimpleUrlHandlerMapping;
import org.springframework.web.reactive.result.SimpleResultHandler;
import org.springframework.web.reactive.result.WebHandlerHandlerAdapter;
import org.springframework.web.server.WebHandler;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.adapter.WebHttpHandlerBuilder;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.web.reactive.method;
package org.springframework.web.reactive.result.method;
import java.lang.reflect.Method;
import java.net.URI;
@ -35,7 +35,7 @@ import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.method.HandlerMethod;
import org.springframework.web.reactive.HandlerResult;
import org.springframework.web.reactive.method.annotation.RequestParamArgumentResolver;
import org.springframework.web.reactive.result.method.annotation.RequestParamArgumentResolver;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.adapter.DefaultServerWebExchange;
import org.springframework.web.server.session.WebSessionManager;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.net.URI;
import java.util.List;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.net.URI;
import java.nio.ByteBuffer;
@ -67,7 +67,7 @@ import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;
import org.springframework.web.reactive.DispatcherHandler;
import org.springframework.web.reactive.ViewResolver;
import org.springframework.web.reactive.handler.SimpleResultHandler;
import org.springframework.web.reactive.result.SimpleResultHandler;
import org.springframework.web.reactive.view.ViewResolverResultHandler;
import org.springframework.web.reactive.view.freemarker.FreeMarkerConfigurer;
import org.springframework.web.reactive.view.freemarker.FreeMarkerViewResolver;

View File

@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.web.reactive.method.annotation;
package org.springframework.web.reactive.result.method.annotation;
import java.util.Collections;