DATAREST-1170 - Update copyright years to 2018.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -49,7 +49,7 @@ class AbstractRepositoryRestController {
|
||||
/**
|
||||
* Creates a new {@link AbstractRepositoryRestController} for the given {@link PagedResourcesAssembler} and
|
||||
* {@link AuditableBeanWrapperFactory}.
|
||||
*
|
||||
*
|
||||
* @param pagedResourcesAssembler must not be {@literal null}.
|
||||
*/
|
||||
public AbstractRepositoryRestController(PagedResourcesAssembler<Object> pagedResourcesAssembler) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -26,7 +26,7 @@ import org.springframework.stereotype.Component;
|
||||
/**
|
||||
* Annotation to declare a controller that declares request mappings to be augmented with a base URI in the Spring Data
|
||||
* REST configuration.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@Documented
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -61,7 +61,7 @@ import org.springframework.web.util.UrlPathHelper;
|
||||
|
||||
/**
|
||||
* A {@link RequestMappingHandlerMapping} that augments the request mappings
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
@@ -74,7 +74,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
|
||||
/**
|
||||
* Creates a new {@link BasePathAwareHandlerMapping} using the given {@link RepositoryRestConfiguration}.
|
||||
*
|
||||
*
|
||||
* @param configuration must not be {@literal null}.
|
||||
*/
|
||||
public BasePathAwareHandlerMapping(RepositoryRestConfiguration configuration) {
|
||||
@@ -83,7 +83,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
this.configuration = configuration;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.handler.AbstractHandlerMethodMapping#lookupHandlerMethod(java.lang.String, javax.servlet.http.HttpServletRequest)
|
||||
*/
|
||||
@@ -113,7 +113,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
return super.lookupHandlerMethod(lookupPath, new CustomAcceptHeaderHttpServletRequest(request, mediaTypes));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping#getMappingForMethod(java.lang.reflect.Method, java.lang.Class)
|
||||
*/
|
||||
@@ -135,7 +135,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
|
||||
/**
|
||||
* Customize the given {@link PatternsRequestCondition} and prefix.
|
||||
*
|
||||
*
|
||||
* @param condition will never be {@literal null}.
|
||||
* @param prefix will never be {@literal null}.
|
||||
* @return
|
||||
@@ -156,7 +156,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
|
||||
/**
|
||||
* Customize the given {@link ProducesRequestCondition}. Default implementation returns the condition as is.
|
||||
*
|
||||
*
|
||||
* @param condition will never be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -164,7 +164,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
return condition;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping#isHandler(java.lang.Class)
|
||||
*/
|
||||
@@ -176,7 +176,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
return type.isAnnotationPresent(BasePathAwareController.class);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping#afterPropertiesSet()
|
||||
*/
|
||||
@@ -574,7 +574,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
/**
|
||||
* Creates a new {@link CustomAcceptHeaderHttpServletRequest} for the given delegate {@link HttpServletRequest} and
|
||||
* the list of {@link MediaType}.
|
||||
*
|
||||
*
|
||||
* @param request must not be {@literal null}.
|
||||
* @param acceptMediaTypes must not be {@literal null} or empty.
|
||||
*/
|
||||
@@ -595,7 +595,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
this.acceptMediaTypeStrings = acceptMediaTypeStrings;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see javax.servlet.http.HttpServletRequestWrapper#getHeader(java.lang.String)
|
||||
*/
|
||||
@@ -609,7 +609,7 @@ public class BasePathAwareHandlerMapping extends RequestMappingHandlerMapping {
|
||||
return super.getHeader(name);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see javax.servlet.http.HttpServletRequestWrapper#getHeaders(java.lang.String)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -32,7 +32,7 @@ import org.springframework.web.util.UrlPathHelper;
|
||||
|
||||
/**
|
||||
* Value object to be able to extract the lookup path within a configured base URI that forms a URI namespace.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class BaseUri {
|
||||
@@ -44,7 +44,7 @@ public class BaseUri {
|
||||
|
||||
/**
|
||||
* Creates a new {@link BaseUri} with the given URI as base.
|
||||
*
|
||||
*
|
||||
* @param uri must not be {@literal null}.
|
||||
*/
|
||||
public BaseUri(URI uri) {
|
||||
@@ -57,7 +57,7 @@ public class BaseUri {
|
||||
|
||||
/**
|
||||
* Creates a new {@link BaseUri} with the given URI as base.
|
||||
*
|
||||
*
|
||||
* @param uri must not be {@literal null}.
|
||||
*/
|
||||
public BaseUri(String uri) {
|
||||
@@ -66,7 +66,7 @@ public class BaseUri {
|
||||
|
||||
/**
|
||||
* Returns the base URI.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public URI getUri() {
|
||||
@@ -76,7 +76,7 @@ public class BaseUri {
|
||||
/**
|
||||
* Extracts the actual lookup path within the Spring Data REST managed URI space. This includes stripping the
|
||||
* necessary parts of the base URI from the source lookup path.
|
||||
*
|
||||
*
|
||||
* @param request must not be {@literal null}.
|
||||
* @return the stripped lookup path with then the repository URI space or {@literal null} in case the lookup path is
|
||||
* not pointing into the repository URI space.
|
||||
@@ -88,7 +88,7 @@ public class BaseUri {
|
||||
/**
|
||||
* Extracts the actual lookup path within the Spring Data REST managed URI space. This includes stripping the
|
||||
* necessary parts of the base URI from the source lookup path.
|
||||
*
|
||||
*
|
||||
* @param request must not be {@literal null}.
|
||||
* @return the stripped lookup path with then the repository URI space or {@literal null} in case the lookup path is
|
||||
* not pointing into the repository URI space.
|
||||
@@ -102,7 +102,7 @@ public class BaseUri {
|
||||
/**
|
||||
* Extracts the actual lookup path within the Spring Data REST managed URI space. This includes stripping the
|
||||
* necessary parts of the base URI from the source lookup path.
|
||||
*
|
||||
*
|
||||
* @param lookupPath must not be {@literal null}.
|
||||
* @return the stripped lookup path with then the repository URI space or {@literal null} in case the lookup path is
|
||||
* not pointing into the repository URI space.
|
||||
@@ -113,7 +113,7 @@ public class BaseUri {
|
||||
|
||||
// Temporary fix for SPR-13455
|
||||
lookupPath = lookupPath.replaceAll("//", "/");
|
||||
|
||||
|
||||
lookupPath = trimTrailingCharacter(lookupPath, '/');
|
||||
|
||||
if (!baseUri.isAbsolute()) {
|
||||
@@ -147,7 +147,7 @@ public class BaseUri {
|
||||
/**
|
||||
* Returns a new {@link UriComponentsBuilder} for the base URI. If the base URI is not absolute, it'll lokup the URI
|
||||
* for the current servlet mapping and extend it accordingly.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public UriComponentsBuilder getUriComponentsBuilder() {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2014 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -47,7 +47,7 @@ public class ControllerUtils {
|
||||
|
||||
/**
|
||||
* Wrap a resource as a {@link ResourceEntity} and attach given headers and status.
|
||||
*
|
||||
*
|
||||
* @param status
|
||||
* @param headers
|
||||
* @param resource
|
||||
@@ -66,7 +66,7 @@ public class ControllerUtils {
|
||||
|
||||
/**
|
||||
* Return an empty response that is only comprised of a status
|
||||
*
|
||||
*
|
||||
* @param status
|
||||
* @return
|
||||
*/
|
||||
@@ -76,7 +76,7 @@ public class ControllerUtils {
|
||||
|
||||
/**
|
||||
* Return an empty response that is only comprised of headers and a status
|
||||
*
|
||||
*
|
||||
* @param status
|
||||
* @param headers
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016-2017 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -35,7 +35,7 @@ import org.springframework.util.Assert;
|
||||
/**
|
||||
* Value object to prepare {@link HttpHeaders} for {@link PersistentEntityResource} and {@link PersistentEntity}
|
||||
* instances.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @soundtrack Ron Spielman Trio - Matchstick
|
||||
*/
|
||||
@@ -52,7 +52,7 @@ public class HttpHeadersPreparer {
|
||||
/**
|
||||
* Returns the default headers to be returned for the given {@link PersistentEntityResource}. Will set {@link ETag}
|
||||
* and {@code Last-Modified} headers if applicable.
|
||||
*
|
||||
*
|
||||
* @param resource can be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -66,7 +66,7 @@ public class HttpHeadersPreparer {
|
||||
/**
|
||||
* Returns the default headers to be returned for the given {@link PersistentEntity} and value. Will set {@link ETag}
|
||||
* and {@code Last-Modified} headers if applicable.
|
||||
*
|
||||
*
|
||||
* @param entity must not be {@literal null}.
|
||||
* @param value must not be {@literal null}.
|
||||
* @return
|
||||
@@ -87,7 +87,7 @@ public class HttpHeadersPreparer {
|
||||
|
||||
/**
|
||||
* Returns whether the given object is still valid in the context of the given {@link HttpHeaders}' requirements.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @param headers must not be {@literal null}.
|
||||
* @return
|
||||
@@ -108,7 +108,7 @@ public class HttpHeadersPreparer {
|
||||
|
||||
/**
|
||||
* Returns the {@link AuditableBeanWrapper} for the given source.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -36,7 +36,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Creates a new {@link IncomingRequest} from {@link ServerHttpRequest}.
|
||||
*
|
||||
*
|
||||
* @param request must not be {@literal null}.
|
||||
*/
|
||||
public IncomingRequest(ServerHttpRequest request) {
|
||||
@@ -49,7 +49,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Returns whether the request is a PATCH request.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public boolean isPatchRequest() {
|
||||
@@ -58,7 +58,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Returns whether the request is a PATCH request with a payload of type {@link RestMediaTypes#JSON_PATCH_JSON}.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public boolean isJsonPatchRequest() {
|
||||
@@ -67,7 +67,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Returns whether the request is a PATCH request with a payload of type {@link RestMediaTypes#MERGE_PATCH_JSON}.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public boolean isJsonMergePatchRequest() {
|
||||
@@ -76,7 +76,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Returns the body of the request.
|
||||
*
|
||||
*
|
||||
* @return will never be {@literal null}.
|
||||
* @throws IOException
|
||||
*/
|
||||
@@ -86,7 +86,7 @@ public class IncomingRequest {
|
||||
|
||||
/**
|
||||
* Returns the underlying {@link ServerHttpRequest}.
|
||||
*
|
||||
*
|
||||
* @return will never be {@literal null}.
|
||||
*/
|
||||
public ServerHttpRequest getServerHttpRequest() {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -34,7 +34,7 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
|
||||
/**
|
||||
* A Spring HATEOAS {@link Resource} subclass that holds a reference to the entity's {@link PersistentEntity} metadata.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -49,7 +49,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
/**
|
||||
* Returns whether the content of the resource is a new entity about to be created. Used to distinguish between
|
||||
* creation and updates for incoming requests.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
private final @Getter boolean isNew;
|
||||
@@ -58,7 +58,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityResource} for the given {@link PersistentEntity}, content, embedded
|
||||
* {@link Resources}, links and flag whether to render all associations.
|
||||
*
|
||||
*
|
||||
* @param entity must not be {@literal null}.
|
||||
* @param content must not be {@literal null}.
|
||||
* @param links must not be {@literal null}.
|
||||
@@ -79,7 +79,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Returns the {@link PersistentEntity} for the underlying instance.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public PersistentEntity<?, ? extends PersistentProperty<?>> getPersistentEntity() {
|
||||
@@ -88,7 +88,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Returns the {@link PersistentPropertyAccessor} for the underlying content bean.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public PersistentPropertyAccessor getPropertyAccessor() {
|
||||
@@ -97,7 +97,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Returns the resources that are supposed to be rendered in the {@code _embedded} clause.
|
||||
*
|
||||
*
|
||||
* @return the embeddeds
|
||||
*/
|
||||
public Iterable<EmbeddedWrapper> getEmbeddeds() {
|
||||
@@ -106,7 +106,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Creates a new {@link Builder} to create {@link PersistentEntityResource}s eventually.
|
||||
*
|
||||
*
|
||||
* @param content must not be {@literal null}.
|
||||
* @param entity must not be {@literal null}.
|
||||
* @return
|
||||
@@ -130,7 +130,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Creates a new {@link Builder} instance for the given content and {@link PersistentEntity}.
|
||||
*
|
||||
*
|
||||
* @param content must not be {@literal null}.
|
||||
* @param entity must not be {@literal null}.
|
||||
*/
|
||||
@@ -146,7 +146,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
/**
|
||||
* Configures the builder to embed the given {@link EmbeddedWrapper} instances. Creates a {@link Resources} instance
|
||||
* to make sure the {@link EmbeddedWrapper} handling gets applied to the serialization output ignoring the links.
|
||||
*
|
||||
*
|
||||
* @param resources can be {@literal null}.
|
||||
* @return the builder
|
||||
*/
|
||||
@@ -158,7 +158,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Adds the given {@link Link} to the {@link PersistentEntityResource}.
|
||||
*
|
||||
*
|
||||
* @param link must not be {@literal null}.
|
||||
* @return the builder
|
||||
*/
|
||||
@@ -180,7 +180,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
|
||||
/**
|
||||
* Finally creates the {@link PersistentEntityResource} instance.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public PersistentEntityResource build() {
|
||||
@@ -190,7 +190,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
/**
|
||||
* Finally creates the {@link PersistentEntityResource} instance to symbolize the contained entity is about to be
|
||||
* created.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public PersistentEntityResource forCreation() {
|
||||
@@ -208,7 +208,7 @@ public class PersistentEntityResource extends Resource<Object> {
|
||||
super(content);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.ResourceSupport#getLinks()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2016 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -32,7 +32,7 @@ import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
* {@link ResourceAssembler} to create {@link PersistentEntityResource}s for arbitrary domain objects.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@@ -44,7 +44,7 @@ public class PersistentEntityResourceAssembler implements ResourceAssembler<Obje
|
||||
private final @NonNull SelfLinkProvider linkProvider;
|
||||
private final @NonNull EmbeddedWrappers wrappers = new EmbeddedWrappers(false);
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.ResourceAssembler#toResource(java.lang.Object)
|
||||
*/
|
||||
@@ -57,7 +57,7 @@ public class PersistentEntityResourceAssembler implements ResourceAssembler<Obje
|
||||
|
||||
/**
|
||||
* Returns the full object as {@link PersistentEntityResource} using the underlying {@link Projector}.
|
||||
*
|
||||
*
|
||||
* @param instance must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -80,7 +80,7 @@ public class PersistentEntityResourceAssembler implements ResourceAssembler<Obje
|
||||
/**
|
||||
* Returns the embedded resources to render. This will add an {@link RelatedResource} for linkable associations if
|
||||
* they have an excerpt projection registered.
|
||||
*
|
||||
*
|
||||
* @param instance must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -90,7 +90,7 @@ public class PersistentEntityResourceAssembler implements ResourceAssembler<Obje
|
||||
|
||||
/**
|
||||
* Creates the self link for the given domain instance.
|
||||
*
|
||||
*
|
||||
* @param instance must be a managed entity, not {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -34,7 +34,7 @@ import org.springframework.web.bind.annotation.RequestMethod;
|
||||
|
||||
/**
|
||||
* Controller for the root resource exposing links to the repository resources.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -48,7 +48,7 @@ public class RepositoryController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* Creates a new {@link RepositoryController} for the given {@link PagedResourcesAssembler}, {@link Repositories},
|
||||
* {@link EntityLinks} and {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @param assembler must not be {@literal null}.
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param entityLinks must not be {@literal null}.
|
||||
@@ -71,7 +71,7 @@ public class RepositoryController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* <code>OPTIONS /</code>.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
* @since 2.2
|
||||
*/
|
||||
@@ -86,7 +86,7 @@ public class RepositoryController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* <code>HEAD /</code>
|
||||
*
|
||||
*
|
||||
* @return
|
||||
* @since 2.2
|
||||
*/
|
||||
@@ -97,7 +97,7 @@ public class RepositoryController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* Lists all repositories exported by creating a link list pointing to resources exposing the repositories.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = { "/", "" }, method = RequestMethod.GET)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2016 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -98,7 +98,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
* Creates a new {@link RepositoryEntityController} for the given {@link Repositories},
|
||||
* {@link RepositoryRestConfiguration}, {@link RepositoryEntityLinks}, {@link PagedResourcesAssembler},
|
||||
* {@link ConversionService} and {@link AuditableBeanWrapperFactory}.
|
||||
*
|
||||
*
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param config must not be {@literal null}.
|
||||
* @param entityLinks must not be {@literal null}.
|
||||
@@ -129,7 +129,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>OPTIONS /{repository}</code>.
|
||||
*
|
||||
*
|
||||
* @param information
|
||||
* @return
|
||||
* @since 2.2
|
||||
@@ -147,7 +147,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>HEAD /{repository}</code>
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @return
|
||||
* @throws HttpRequestMethodNotSupportedException
|
||||
@@ -176,7 +176,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>GET /{repository}</code> - Returns the collection resource (paged or unpaged).
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param pageable
|
||||
* @param sort
|
||||
@@ -252,7 +252,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>POST /{repository}</code> - Creates a new entity instances from the collection resource.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param payload
|
||||
* @param assembler
|
||||
@@ -275,7 +275,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>OPTIONS /{repository}/{id}<code>
|
||||
*
|
||||
*
|
||||
* @param information
|
||||
* @return
|
||||
* @since 2.2
|
||||
@@ -294,7 +294,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>HEAD /{repsoitory}/{id}</code>
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param id
|
||||
* @return
|
||||
@@ -319,7 +319,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>GET /{repository}/{id}</code> - Returns a single entity.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param id
|
||||
* @return
|
||||
@@ -342,7 +342,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* <code>PUT /{repository}/{id}</code> - Updates an existing entity or creates one at exactly that place.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param payload
|
||||
* @param id
|
||||
@@ -464,7 +464,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* Triggers the creation of the domain object and renders it into the response if needed.
|
||||
*
|
||||
*
|
||||
* @param domainObject
|
||||
* @param invoker
|
||||
* @return
|
||||
@@ -488,7 +488,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
/**
|
||||
* Sets the location header pointing to the resource representing the given instance. Will make sure we properly
|
||||
* expand the URI template potentially created as self link.
|
||||
*
|
||||
*
|
||||
* @param headers must not be {@literal null}.
|
||||
* @param assembler must not be {@literal null}.
|
||||
* @param source must not be {@literal null}.
|
||||
@@ -501,7 +501,7 @@ class RepositoryEntityController extends AbstractRepositoryRestController implem
|
||||
|
||||
/**
|
||||
* Returns the object backing the item resource for the given {@link RootResourceInformation} and id.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param id
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2015 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -19,7 +19,7 @@ import org.springframework.hateoas.ResourceSupport;
|
||||
|
||||
/**
|
||||
* Dedicated resource type to represent the links pointing to collection resources exposed for repositories.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -99,7 +99,7 @@ class RepositoryPropertyReferenceController extends AbstractRepositoryRestContro
|
||||
this.repositoryInvokerFactory = repositoryInvokerFactory;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.context.ApplicationEventPublisherAware#setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher)
|
||||
*/
|
||||
@@ -478,7 +478,7 @@ class RepositoryPropertyReferenceController extends AbstractRepositoryRestContro
|
||||
String.format(message, parameters));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Throwable#getMessage()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2015 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -26,7 +26,7 @@ import org.springframework.stereotype.Component;
|
||||
/**
|
||||
* Annotation to demarcate Spring MVC controllers provided by Spring Data REST. Allows to easily detect them and exclude
|
||||
* them from standard Spring MVC handling.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@Documented
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -40,7 +40,7 @@ import org.springframework.web.bind.annotation.ExceptionHandler;
|
||||
|
||||
/**
|
||||
* Exception handler for Spring Data REST controllers.
|
||||
*
|
||||
*
|
||||
* @author Thibaud Lepretre
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -53,7 +53,7 @@ public class RepositoryRestExceptionHandler {
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositoryRestExceptionHandler} using the given {@link MessageSource}.
|
||||
*
|
||||
*
|
||||
* @param messageSource must not be {@literal null}.
|
||||
*/
|
||||
public RepositoryRestExceptionHandler(MessageSource messageSource) {
|
||||
@@ -64,7 +64,7 @@ public class RepositoryRestExceptionHandler {
|
||||
|
||||
/**
|
||||
* Handles {@link ResourceNotFoundException} by returning {@code 404 Not Found}.
|
||||
*
|
||||
*
|
||||
* @param o_O the exception to handle.
|
||||
* @return
|
||||
*/
|
||||
@@ -75,7 +75,7 @@ public class RepositoryRestExceptionHandler {
|
||||
|
||||
/**
|
||||
* Handles {@link HttpMessageNotReadableException} by returning {@code 400 Bad Request}.
|
||||
*
|
||||
*
|
||||
* @param o_O the exception to handle.
|
||||
* @return
|
||||
*/
|
||||
@@ -100,7 +100,7 @@ public class RepositoryRestExceptionHandler {
|
||||
|
||||
/**
|
||||
* Handles {@link RepositoryConstraintViolationException}s by returning {@code 400 Bad Request}.
|
||||
*
|
||||
*
|
||||
* @param o_O the exception to handle.
|
||||
* @return
|
||||
*/
|
||||
@@ -140,7 +140,7 @@ public class RepositoryRestExceptionHandler {
|
||||
|
||||
/**
|
||||
* Handles {@link ETagDoesntMatchException} by returning {@code 412 Precondition Failed}.
|
||||
*
|
||||
*
|
||||
* @param o_O the exception to handle.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2016 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -28,7 +28,7 @@ import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandl
|
||||
* parameters used in the REST exporter controller. Also only looks for handler methods in the Spring Data REST provided
|
||||
* controller classes to help isolate this handler adapter from other handler adapters the user might have configured in
|
||||
* their Spring MVC context.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -40,7 +40,7 @@ public class RepositoryRestHandlerAdapter
|
||||
/**
|
||||
* Creates a new {@link RepositoryRestHandlerAdapter} using the given {@link HandlerMethodArgumentResolver} and
|
||||
* {@link org.springframework.hateoas.mvc.ResourceProcessorInvoker}.
|
||||
*
|
||||
*
|
||||
* @param argumentResolvers must not be {@literal null}.
|
||||
* @param invoker must not be {@literal null}.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -154,7 +154,7 @@ public class RepositoryRestHandlerMapping extends BasePathAwareHandlerMapping {
|
||||
return mappings.exportsTopLevelResourceFor(getRepositoryBasePath(repositoryLookupPath)) ? handlerMethod : null;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping#handleNoMatch(java.util.Set, java.lang.String, javax.servlet.http.HttpServletRequest)
|
||||
*/
|
||||
@@ -189,7 +189,7 @@ public class RepositoryRestHandlerMapping extends BasePathAwareHandlerMapping {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.BasePathAwareHandlerMapping#process(org.springframework.web.servlet.mvc.condition.ProducesRequestCondition)
|
||||
*/
|
||||
@@ -245,7 +245,7 @@ public class RepositoryRestHandlerMapping extends BasePathAwareHandlerMapping {
|
||||
|
||||
INSTANCE;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.util.StringValueResolver#resolveStringValue(java.lang.String)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2017 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -28,7 +28,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
/**
|
||||
* Controller to expose a JSON schema via {@code /repository/schema}.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
@@ -41,7 +41,7 @@ class RepositorySchemaController {
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositorySchemaController} using the given {@link PersistentEntityToJsonSchemaConverter}.
|
||||
*
|
||||
*
|
||||
* @param jsonSchemaConverter must not be {@literal null}.
|
||||
*/
|
||||
@Autowired
|
||||
@@ -54,7 +54,7 @@ class RepositorySchemaController {
|
||||
|
||||
/**
|
||||
* Exposes a JSON schema for the repository referenced.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation will never be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2015 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -67,7 +67,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
/**
|
||||
* Controller to lookup and execute searches on a given repository.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -84,7 +84,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* Creates a new {@link RepositorySearchController} using the given {@link PagedResourcesAssembler},
|
||||
* {@link EntityLinks} and {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @param assembler must not be {@literal null}.
|
||||
* @param entityLinks must not be {@literal null}.
|
||||
* @param mappings must not be {@literal null}.
|
||||
@@ -105,7 +105,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* <code>OPTIONS /{repository}/search</code>.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @return
|
||||
* @since 2.2
|
||||
@@ -123,7 +123,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* <code>HEAD /{repository}/search</code> - Checks whether the search resource is present.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @return
|
||||
*/
|
||||
@@ -138,7 +138,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* <code>GET /{repository}/search</code> - Exposes links to the individual search resources exposed by the backing
|
||||
* repository.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @return
|
||||
*/
|
||||
@@ -163,7 +163,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* Executes the search with the given name.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param parameters
|
||||
* @param search
|
||||
@@ -193,7 +193,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* Turns the given source into a {@link ResourceSupport} if needed and possible. Uses the given
|
||||
* {@link PersistentEntityResourceAssembler} for the actual conversion.
|
||||
*
|
||||
*
|
||||
* @param source can be must not be {@literal null}.
|
||||
* @param assembler must not be {@literal null}.
|
||||
* @param domainType the domain type in case the source is an empty iterable, must not be {@literal null}.
|
||||
@@ -226,7 +226,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* Executes a query method and exposes the results in compact form.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param parameters
|
||||
* @param repository
|
||||
@@ -274,7 +274,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* <code>OPTIONS /{repository}/search/{search}</code>.
|
||||
*
|
||||
*
|
||||
* @param information
|
||||
* @param search
|
||||
* @return
|
||||
@@ -293,7 +293,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* Handles a {@code HEAD} request for individual searches.
|
||||
*
|
||||
*
|
||||
* @param information
|
||||
* @param search
|
||||
* @return
|
||||
@@ -309,7 +309,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* Checks that the given request is actually executable. Will reject execution if we don't find a search with the
|
||||
* given name.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
* @param searchName
|
||||
* @return
|
||||
@@ -367,7 +367,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
|
||||
/**
|
||||
* Verifies that the given {@link RootResourceInformation} has searches exposed.
|
||||
*
|
||||
*
|
||||
* @param resourceInformation
|
||||
*/
|
||||
private static SearchResourceMappings verifySearchesExposed(RootResourceInformation resourceInformation) {
|
||||
@@ -384,7 +384,7 @@ class RepositorySearchController extends AbstractRepositoryRestController {
|
||||
/**
|
||||
* Tries to turn all elements of the given {@link List} into URIs and falls back to keeping the original element if
|
||||
* the conversion fails.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -24,7 +24,7 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
/**
|
||||
* A custom {@link ResourceSupport} type to be able to write custom {@link ResourceProcessor}s to add additional links
|
||||
* to ones automatically exposed for Spring Data repository query methods.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class RepositorySearchesResource extends ResourceSupport {
|
||||
@@ -33,7 +33,7 @@ public class RepositorySearchesResource extends ResourceSupport {
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositorySearchesResource} for the given domain type.
|
||||
*
|
||||
*
|
||||
* @param domainType must not be {@literal null}.
|
||||
*/
|
||||
RepositorySearchesResource(Class<?> domainType) {
|
||||
@@ -44,7 +44,7 @@ public class RepositorySearchesResource extends ResourceSupport {
|
||||
|
||||
/**
|
||||
* Returns the domain type for which the resource lists searches.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@JsonIgnore
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2014 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -20,7 +20,7 @@ import org.springframework.web.bind.annotation.ResponseStatus;
|
||||
|
||||
/**
|
||||
* Indicates a resource was not found.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2016 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -37,7 +37,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
/**
|
||||
* {@link HandlerMethodReturnValueHandler} to post-process the objects returned from controller methods using the
|
||||
* configured {@link ResourceProcessor}s.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @deprecated use the same type from Spring HATEOAS, will be removed in 2.7.
|
||||
*/
|
||||
@@ -119,7 +119,7 @@ public class ResourceProcessorHandlerMethodReturnValueHandler implements Handler
|
||||
* Re-wraps the result of the post-processing work into an {@link HttpEntity} or {@link ResponseEntity} if the
|
||||
* original value was one of those two types. Copies headers and status code from the original value but uses the new
|
||||
* body.
|
||||
*
|
||||
*
|
||||
* @param newBody the post-processed value.
|
||||
* @param originalValue the original input value.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016-2017 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -49,7 +49,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Creates a new {@link ResourceProcessorInvoker} to consider the given {@link ResourceProcessor} to post-process the
|
||||
* controller methods return value to before invoking the delegate.
|
||||
*
|
||||
*
|
||||
* @param processors the {@link ResourceProcessor}s to be considered, must not be {@literal null}.
|
||||
*/
|
||||
public ResourceProcessorInvoker(Collection<ResourceProcessor<?>> processors) {
|
||||
@@ -77,7 +77,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Invokes all {@link ResourceProcessor} instances registered for the type of the given value.
|
||||
*
|
||||
*
|
||||
* @param value must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -90,7 +90,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Invokes all {@link ResourceProcessor} instances registered for the type of the given value and reference type.
|
||||
*
|
||||
*
|
||||
* @param value must not be {@literal null}.
|
||||
* @param referenceType must not be {@literal null}.
|
||||
* @return
|
||||
@@ -128,7 +128,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Invokes all registered {@link ResourceProcessor}s registered for the given {@link ResolvableType}.
|
||||
*
|
||||
*
|
||||
* @param value the object to process
|
||||
* @param type
|
||||
* @return
|
||||
@@ -160,7 +160,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Interface to unify interaction with {@link ResourceProcessor}s. The {@link Ordered} rank should be determined by
|
||||
* the underlying processor.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private interface ProcessorWrapper extends Ordered {
|
||||
@@ -168,7 +168,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Returns whether the underlying processor supports the given {@link ResolvableType}. It might also additionally
|
||||
* inspect the object that would eventually be handed to the processor.
|
||||
*
|
||||
*
|
||||
* @param type the type of object to be post processed, will never be {@literal null}.
|
||||
* @param value the object that would be passed into the processor eventually, can be {@literal null}.
|
||||
* @return
|
||||
@@ -178,7 +178,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Performs the actual invocation of the processor. Implementations can be sure
|
||||
* {@link #supports(ResolvableType, Object)} has been called before and returned {@literal true}.
|
||||
*
|
||||
*
|
||||
* @param object
|
||||
*/
|
||||
Object invokeProcessor(Object object);
|
||||
@@ -186,7 +186,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Default implementation of {@link ProcessorWrapper} to generically deal with {@link ResourceSupport} types.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private static class DefaultProcessorWrapper implements ResourceProcessorInvoker.ProcessorWrapper {
|
||||
@@ -196,7 +196,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Creates a new {@link DefaultProcessorWrapper} with the given {@link ResourceProcessor}.
|
||||
*
|
||||
*
|
||||
* @param processor must not be {@literal null}.
|
||||
*/
|
||||
public DefaultProcessorWrapper(ResourceProcessor<?> processor) {
|
||||
@@ -216,7 +216,7 @@ public class ResourceProcessorInvoker {
|
||||
return isRawTypeAssignable(targetType, getRawType(type));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.ResourceProcessorHandlerMethodReturnValueHandler.PostProcessorWrapper#invokeProcessor(java.lang.Object)
|
||||
*/
|
||||
@@ -237,7 +237,7 @@ public class ResourceProcessorInvoker {
|
||||
|
||||
/**
|
||||
* Returns the target type the underlying {@link ResourceProcessor} wants to get invoked for.
|
||||
*
|
||||
*
|
||||
* @return the targetType
|
||||
*/
|
||||
public ResolvableType getTargetType() {
|
||||
@@ -248,14 +248,14 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* {@link ProcessorWrapper} to deal with {@link ResourceProcessor}s for {@link Resource}s. Will fall back to peeking
|
||||
* into the {@link Resource}'s content for type resolution.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private static class ResourceProcessorWrapper extends ResourceProcessorInvoker.DefaultProcessorWrapper {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResourceProcessorWrapper} for the given {@link ResourceProcessor}.
|
||||
*
|
||||
*
|
||||
* @param processor must not be {@literal null}.
|
||||
*/
|
||||
public ResourceProcessorWrapper(ResourceProcessor<?> processor) {
|
||||
@@ -279,7 +279,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Returns whether the given {@link Resource} matches the given target {@link ResolvableType}. We inspect the
|
||||
* {@link Resource}'s value to determine the match.
|
||||
*
|
||||
*
|
||||
* @param resource
|
||||
* @param target must not be {@literal null}.
|
||||
* @return whether the given {@link Resource} can be assigned to the given target {@link ResolvableType}
|
||||
@@ -319,14 +319,14 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* {@link ProcessorWrapper} for {@link ResourceProcessor}s targeting {@link Resources}. Will peek into the content of
|
||||
* the {@link Resources} for type matching decisions if needed.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
static class ResourcesProcessorWrapper extends ResourceProcessorInvoker.DefaultProcessorWrapper {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResourcesProcessorWrapper} for the given {@link ResourceProcessor}.
|
||||
*
|
||||
*
|
||||
* @param processor must not be {@literal null}.
|
||||
*/
|
||||
public ResourcesProcessorWrapper(ResourceProcessor<?> processor) {
|
||||
@@ -350,7 +350,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Returns whether the given {@link Resources} instance matches the given {@link ResolvableType}. We predict this by
|
||||
* inspecting the first element of the content of the {@link Resources}.
|
||||
*
|
||||
*
|
||||
* @param resources the {@link Resources} to inspect.
|
||||
* @param target that target {@link ResolvableType}.
|
||||
* @return
|
||||
@@ -398,7 +398,7 @@ public class ResourceProcessorInvoker {
|
||||
/**
|
||||
* Helper extension of {@link AnnotationAwareOrderComparator} to make {@link #getOrder(Object)} public to allow it
|
||||
* being used in a standalone fashion.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private static class CustomOrderAwareComparator extends AnnotationAwareOrderComparator {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -35,7 +35,7 @@ import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandl
|
||||
* <p/>
|
||||
* This is a separate component as it might make sense to deploy it in a standalone SpringMVC application to enable post
|
||||
* processing. It would actually make most sense in Spring HATEOAS project.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Phil Webb
|
||||
* @author Mark Paluch
|
||||
@@ -51,7 +51,7 @@ public class ResourceProcessorInvokingHandlerAdapter extends RequestMappingHandl
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResourceProcessorInvokingHandlerAdapter} with the given {@link ResourceProcessorInvoker}.
|
||||
*
|
||||
*
|
||||
* @param invoker must not be {@literal null}.
|
||||
*/
|
||||
@Autowired(required = false)
|
||||
@@ -84,7 +84,7 @@ public class ResourceProcessorInvokingHandlerAdapter extends RequestMappingHandl
|
||||
/**
|
||||
* Gets a {@link HandlerMethodReturnValueHandlerComposite} for return handlers, dealing with API changes introduced in
|
||||
* Spring 4.0.
|
||||
*
|
||||
*
|
||||
* @return a HandlerMethodReturnValueHandlerComposite
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -34,7 +34,7 @@ import org.springframework.util.Assert;
|
||||
/**
|
||||
* Simple abstraction to capture the status of a resource to determine whether it has been modified or not and produce
|
||||
* {@link ResponseEntity} via its {@link StatusAndHeaders} sub component.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.6
|
||||
* @soundtrack Blumentopf - Dass ich nicht lache (Kein Zufall)
|
||||
@@ -49,7 +49,7 @@ class ResourceStatus {
|
||||
/**
|
||||
* Returns the {@link StatusAndHeaders} calculated from the given {@link HttpHeaders}, domain object and
|
||||
* {@link RootResourceInformation.
|
||||
*
|
||||
*
|
||||
* @param requestHeaders must not be {@literal null}.
|
||||
* @param domainObject must not be {@literal null}.
|
||||
* @param entity must not be {@literal null}.
|
||||
@@ -93,7 +93,7 @@ class ResourceStatus {
|
||||
|
||||
/**
|
||||
* Creates a {@link ResponseEntity} based on the given {@link PersistentEntityResource}.
|
||||
*
|
||||
*
|
||||
* @param supplier a {@link Supplier} to provide a {@link PersistentEntityResource} eventually, must not be
|
||||
* {@literal null}.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -20,7 +20,7 @@ import org.springframework.http.MediaType;
|
||||
|
||||
/**
|
||||
* Constants to refer to supported media types.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -32,7 +32,7 @@ import org.springframework.web.HttpRequestMethodNotSupportedException;
|
||||
|
||||
/**
|
||||
* Meta-information about the root repository resource.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -83,7 +83,7 @@ public class RootResourceInformation {
|
||||
|
||||
/**
|
||||
* Verifies that the given {@link HttpMethod} is supported for the given {@link ResourceType}.
|
||||
*
|
||||
*
|
||||
* @param httpMethod must not be {@literal null}.
|
||||
* @param resourceType must not be {@literal null}.
|
||||
* @throws ResourceNotFoundException if the repository is not exported at all.
|
||||
@@ -110,7 +110,7 @@ public class RootResourceInformation {
|
||||
|
||||
/**
|
||||
* Verifies that the given {@link HttpMethod} is supported for the given {@link PersistentProperty}.
|
||||
*
|
||||
*
|
||||
* @param httpMethod must not be {@literal null}.
|
||||
* @param property must not be {@literal null}.
|
||||
* @throws ResourceNotFoundException if the repository is not exported at all.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -39,7 +39,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
/**
|
||||
* Controller exposing semantic documentation for the resources exposed using the Application Level Profile Semantics
|
||||
* format.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
* @see <a href="http://alps.io">http://alps.io</a>
|
||||
@@ -51,7 +51,7 @@ public class AlpsController {
|
||||
|
||||
/**
|
||||
* Creates a new {@link AlpsController} for the given {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @param configuration must not be {@literal null}.
|
||||
*/
|
||||
@Autowired
|
||||
@@ -64,7 +64,7 @@ public class AlpsController {
|
||||
|
||||
/**
|
||||
* Exposes the allowed HTTP methods for the ALPS resources.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = ProfileController.RESOURCE_PROFILE_MAPPING, method = OPTIONS,
|
||||
@@ -81,7 +81,7 @@ public class AlpsController {
|
||||
|
||||
/**
|
||||
* Exposes an ALPS resource to describe an individual repository resource.
|
||||
*
|
||||
*
|
||||
* @param information
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -38,7 +38,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
/**
|
||||
* {@link HttpMessageConverter} to render {@link Alps} and {@link RootResourceInformation} instances as
|
||||
* {@code application/alps+json}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConverter
|
||||
@@ -48,7 +48,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
|
||||
/**
|
||||
* Creates a new {@link AlpsJsonHttpMessageConverter} for the given {@link Converter}.
|
||||
*
|
||||
*
|
||||
* @param converter must not be {@literal null}.
|
||||
*/
|
||||
public AlpsJsonHttpMessageConverter(RootResourceInformationToAlpsDescriptorConverter converter) {
|
||||
@@ -64,7 +64,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
setSupportedMediaTypes(Arrays.asList(RestMediaTypes.ALPS_JSON, MediaType.APPLICATION_JSON, MediaType.ALL));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.http.converter.json.MappingJackson2HttpMessageConverter#canWrite(java.lang.Class, org.springframework.http.MediaType)
|
||||
*/
|
||||
@@ -74,7 +74,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
&& super.canWrite(clazz, mediaType);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.http.converter.AbstractGenericHttpMessageConverter#canWrite(java.lang.reflect.Type, java.lang.Class, org.springframework.http.MediaType)
|
||||
*/
|
||||
@@ -83,7 +83,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
return canWrite(clazz, mediaType);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.http.converter.json.MappingJackson2HttpMessageConverter#canRead(java.lang.reflect.Type, java.lang.Class, org.springframework.http.MediaType)
|
||||
*/
|
||||
@@ -92,7 +92,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.annotation.ResponseBodyAdvice#beforeBodyWrite(java.lang.Object, org.springframework.core.MethodParameter, org.springframework.http.MediaType, java.lang.Class, org.springframework.http.server.ServerHttpRequest, org.springframework.http.server.ServerHttpResponse)
|
||||
*/
|
||||
@@ -105,7 +105,7 @@ public class AlpsJsonHttpMessageConverter extends MappingJackson2HttpMessageConv
|
||||
? Collections.singletonMap("alps", converter.convert((RootResourceInformation) body)) : body;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.mvc.method.annotation.ResponseBodyAdvice#supports(org.springframework.core.MethodParameter, java.lang.Class)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -73,7 +73,7 @@ import com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition;
|
||||
|
||||
/**
|
||||
* Converter to create Alps {@link Descriptor} instances for a {@link RootResourceInformation}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
*/
|
||||
@@ -160,7 +160,7 @@ public class RootResourceInformationToAlpsDescriptorConverter {
|
||||
|
||||
/**
|
||||
* Builds a descriptor for the projection parameter of the given resource.
|
||||
*
|
||||
*
|
||||
* @param metadata
|
||||
* @return
|
||||
*/
|
||||
@@ -250,7 +250,7 @@ public class RootResourceInformationToAlpsDescriptorConverter {
|
||||
|
||||
/**
|
||||
* Creates the {@link Descriptor}s for pagination parameters.
|
||||
*
|
||||
*
|
||||
* @param type
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -35,7 +35,7 @@ import org.springframework.web.util.UriComponentsBuilder;
|
||||
/**
|
||||
* {@link PagingAndSortingTemplateVariables} implementation to delegate to the HATEOAS-enabled
|
||||
* {@link HandlerMethodArgumentResolver}s for {@link Pageable} and {@link Sort}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.3
|
||||
*/
|
||||
@@ -50,7 +50,7 @@ class ArgumentResolverPagingAndSortingTemplateVariables implements PagingAndSort
|
||||
/**
|
||||
* Creates a new {@link ArgumentResolverPagingAndSortingTemplateVariables} using the given
|
||||
* {@link HateoasPageableHandlerMethodArgumentResolver} and {@link HateoasSortHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @param pagingResolver must not be {@literal null}.
|
||||
* @param sortResolver must not be {@literal null}.
|
||||
*/
|
||||
@@ -64,7 +64,7 @@ class ArgumentResolverPagingAndSortingTemplateVariables implements PagingAndSort
|
||||
this.sortResolver = sortResolver;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.support.PagingAndSortingTemplateVariables#getPaginationTemplateVariables(org.springframework.core.MethodParameter, org.springframework.web.util.UriComponents)
|
||||
*/
|
||||
@@ -73,7 +73,7 @@ class ArgumentResolverPagingAndSortingTemplateVariables implements PagingAndSort
|
||||
return pagingResolver.getPaginationTemplateVariables(parameter, components);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.support.PagingAndSortingTemplateVariables#getSortTemplateVariables(org.springframework.core.MethodParameter, org.springframework.web.util.UriComponents)
|
||||
*/
|
||||
@@ -82,7 +82,7 @@ class ArgumentResolverPagingAndSortingTemplateVariables implements PagingAndSort
|
||||
return sortResolver.getSortTemplateVariables(parameter, template);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.mvc.UriComponentsContributor#enhance(org.springframework.web.util.UriComponentsBuilder, org.springframework.core.MethodParameter, java.lang.Object)
|
||||
*/
|
||||
@@ -96,7 +96,7 @@ class ArgumentResolverPagingAndSortingTemplateVariables implements PagingAndSort
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.mvc.UriComponentsContributor#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -34,7 +34,7 @@ import com.fasterxml.jackson.databind.node.ObjectNode;
|
||||
* JSON Patch library by Francis Galiegue but applies a customization to remove operations. As the patched node set
|
||||
* needs to be applied to the existing domain objects (see {@link DomainObjectReader} for that) we turn remove calls
|
||||
* into
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Mathias Düsterhöft
|
||||
* @see <a href="http://tools.ietf.org/html/rfc6902">http://tools.ietf.org/html/rfc6902</a>
|
||||
@@ -49,7 +49,7 @@ class JsonPatchHandler {
|
||||
|
||||
/**
|
||||
* Creates a new {@link JsonPatchHandler} with the given {@link ObjectMapper} and {@link DomainObjectReader}.
|
||||
*
|
||||
*
|
||||
* @param mapper must not be {@literal null}.
|
||||
* @param reader must not be {@literal null}.
|
||||
*/
|
||||
@@ -67,7 +67,7 @@ class JsonPatchHandler {
|
||||
|
||||
/**
|
||||
* Applies the body of the given {@link IncomingRequest} as patch on the given target object.
|
||||
*
|
||||
*
|
||||
* @param request must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
* @return
|
||||
@@ -101,7 +101,7 @@ class JsonPatchHandler {
|
||||
|
||||
/**
|
||||
* Returns all {@link JsonPatchOperation}s to be applied.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @return
|
||||
* @throws HttpMessageNotReadableException in case the payload can't be read.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -33,7 +33,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to create {@link PersistentEntityResourceAssembler}s.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@@ -45,7 +45,7 @@ public class PersistentEntityResourceAssemblerArgumentResolver implements Handle
|
||||
private final @NonNull ProjectionFactory projectionFactory;
|
||||
private final @NonNull Associations links;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
@@ -54,7 +54,7 @@ public class PersistentEntityResourceAssemblerArgumentResolver implements Handle
|
||||
return PersistentEntityResourceAssembler.class.equals(parameter.getParameterType());
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#resolveArgument(org.springframework.core.MethodParameter, org.springframework.web.method.support.ModelAndViewContainer, org.springframework.web.context.request.NativeWebRequest, org.springframework.web.bind.support.WebDataBinderFactory)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -52,7 +52,7 @@ import com.fasterxml.jackson.databind.node.ObjectNode;
|
||||
|
||||
/**
|
||||
* Custom {@link HandlerMethodArgumentResolver} to create {@link PersistentEntityResource} instances.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -70,7 +70,7 @@ public class PersistentEntityResourceHandlerMethodArgumentResolver implements Ha
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityResourceHandlerMethodArgumentResolver} for the given
|
||||
* {@link HttpMessageConverter}s and {@link RootResourceInformationHandlerMethodArgumentResolver}..
|
||||
*
|
||||
*
|
||||
* @param messageConverters must not be {@literal null}.
|
||||
* @param resourceInformationResolver must not be {@literal null}.
|
||||
* @param idResolver must not be {@literal null}.
|
||||
@@ -159,7 +159,7 @@ public class PersistentEntityResourceHandlerMethodArgumentResolver implements Ha
|
||||
/**
|
||||
* Reads the given {@link ServerHttpRequest} into an object of the type of the given {@link RootResourceInformation},
|
||||
* potentially applying the content to an object of the given id.
|
||||
*
|
||||
*
|
||||
* @param information must not be {@literal null}.
|
||||
* @param request must not be {@literal null}.
|
||||
* @param converter must not be {@literal null}.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -32,7 +32,7 @@ import org.springframework.util.Assert;
|
||||
* registered with the {@link RepositoryRestConfiguration}. This rather external configuration has been used to make
|
||||
* sure we don't introduce a cyclic dependency between {@link RepositoryRestConfiguration} an
|
||||
* {@link RepositoryResourceMappings} as the latter need access to the former to discover mappings in the first place.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.5
|
||||
* @soundtrack Katinka - Ausverkauf
|
||||
@@ -43,7 +43,7 @@ public class ProjectionDefinitionRegistar extends InstantiationAwareBeanPostProc
|
||||
|
||||
/**
|
||||
* Creates a new {@link ProjectionDefinitionRegistar} for the given {@link RepositoryRestConfiguration}.
|
||||
*
|
||||
*
|
||||
* @param config must not be {@literal null}.
|
||||
*/
|
||||
public ProjectionDefinitionRegistar(ObjectFactory<RepositoryRestConfiguration> config) {
|
||||
@@ -53,7 +53,7 @@ public class ProjectionDefinitionRegistar extends InstantiationAwareBeanPostProc
|
||||
this.config = config;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.beans.factory.config.InstantiationAwareBeanPostProcessorAdapter#postProcessAfterInitialization(java.lang.Object, java.lang.String)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015-2017 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -42,7 +42,7 @@ import com.querydsl.core.types.Predicate;
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to create {@link RootResourceInformation} for injection into Spring MVC
|
||||
* controller methods.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.4
|
||||
*/
|
||||
@@ -56,7 +56,7 @@ class QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver
|
||||
/**
|
||||
* Creates a new {@link QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver} using the given
|
||||
* {@link Repositories}, {@link RepositoryInvokerFactory} and {@link ResourceMetadataHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param invokerFactory must not be {@literal null}.
|
||||
* @param resourceMetadataResolver must not be {@literal null}.
|
||||
@@ -72,7 +72,7 @@ class QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver
|
||||
this.factory = factory;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RootResourceInformationHandlerMethodArgumentResolver#postProcess(org.springframework.data.repository.support.RepositoryInvoker, java.lang.Class, java.util.Map)
|
||||
*/
|
||||
@@ -111,7 +111,7 @@ class QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver
|
||||
|
||||
/**
|
||||
* Converts the given Map into a {@link MultiValueMap}.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -27,7 +27,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
|
||||
/**
|
||||
* Component to configure and customize the setup of Spring Data REST.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.4
|
||||
* @soundtrack Florian Reichelt & Max Ender - Abschlusskonzert (https://www.youtube.com/watch?v=5WP0P-ndinY)
|
||||
@@ -36,21 +36,21 @@ public interface RepositoryRestConfigurer {
|
||||
|
||||
/**
|
||||
* Override this method to add additional configuration.
|
||||
*
|
||||
*
|
||||
* @param config Main configuration bean.
|
||||
*/
|
||||
void configureRepositoryRestConfiguration(RepositoryRestConfiguration config);
|
||||
|
||||
/**
|
||||
* Override this method to add your own converters.
|
||||
*
|
||||
*
|
||||
* @param conversionService Default ConversionService bean.
|
||||
*/
|
||||
void configureConversionService(ConfigurableConversionService conversionService);
|
||||
|
||||
/**
|
||||
* Override this method to add validators manually.
|
||||
*
|
||||
*
|
||||
* @param validatingListener The {@link org.springframework.context.ApplicationListener} responsible for invoking
|
||||
* {@link org.springframework.validation.Validator} instances.
|
||||
*/
|
||||
@@ -58,21 +58,21 @@ public interface RepositoryRestConfigurer {
|
||||
|
||||
/**
|
||||
* Configure the {@link ExceptionHandlerExceptionResolver}.
|
||||
*
|
||||
*
|
||||
* @param exceptionResolver The default exception resolver on which you can add custom argument resolvers.
|
||||
*/
|
||||
void configureExceptionHandlerExceptionResolver(ExceptionHandlerExceptionResolver exceptionResolver);
|
||||
|
||||
/**
|
||||
* Configure the available {@link HttpMessageConverter}s by adding your own.
|
||||
*
|
||||
*
|
||||
* @param messageConverters The converters to be used by the system.
|
||||
*/
|
||||
void configureHttpMessageConverters(List<HttpMessageConverter<?>> messageConverters);
|
||||
|
||||
/**
|
||||
* Configure the Jackson {@link ObjectMapper} directly.
|
||||
*
|
||||
*
|
||||
* @param objectMapper The {@literal ObjectMapper} to be used by the system.
|
||||
*/
|
||||
void configureJacksonObjectMapper(ObjectMapper objectMapper);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -27,49 +27,49 @@ import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
|
||||
/**
|
||||
* Convenience adapter for {@link RepositoryRestConfigurer} to allow selective override of configuration methods.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.4
|
||||
* @soundtrack Florian Reichelt & Max Ender - Abschlusskonzert (https://www.youtube.com/watch?v=5WP0P-ndinY)
|
||||
*/
|
||||
public class RepositoryRestConfigurerAdapter implements RepositoryRestConfigurer {
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureRepositoryRestConfiguration(org.springframework.data.rest.core.config.RepositoryRestConfiguration)
|
||||
*/
|
||||
@Override
|
||||
public void configureRepositoryRestConfiguration(RepositoryRestConfiguration config) {}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureConversionService(org.springframework.core.convert.support.ConfigurableConversionService)
|
||||
*/
|
||||
@Override
|
||||
public void configureConversionService(ConfigurableConversionService conversionService) {}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureValidatingRepositoryEventListener(org.springframework.data.rest.core.event.ValidatingRepositoryEventListener)
|
||||
*/
|
||||
@Override
|
||||
public void configureValidatingRepositoryEventListener(ValidatingRepositoryEventListener validatingListener) {}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureExceptionHandlerExceptionResolver(org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver)
|
||||
*/
|
||||
@Override
|
||||
public void configureExceptionHandlerExceptionResolver(ExceptionHandlerExceptionResolver exceptionResolver) {}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureHttpMessageConverters(java.util.List)
|
||||
*/
|
||||
@Override
|
||||
public void configureHttpMessageConverters(List<HttpMessageConverter<?>> messageConverters) {}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureJacksonObjectMapper(com.fasterxml.jackson.databind.ObjectMapper)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -29,7 +29,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
/**
|
||||
* Delegating implementation of {@link RepositoryRestConfigurer} that will forward all calls to configuration methods to
|
||||
* all registered {@link RepositoryRestConfigurer}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @soundtrack Florian Reichelt & Max Ender - Abschlusskonzert (https://www.youtube.com/watch?v=5WP0P-ndinY)
|
||||
*/
|
||||
@@ -39,7 +39,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositoryRestConfigurerDelegate} for the given {@link RepositoryRestConfigurer}s.
|
||||
*
|
||||
*
|
||||
* @param delegates must not be {@literal null}.
|
||||
*/
|
||||
public RepositoryRestConfigurerDelegate(Iterable<RepositoryRestConfigurer> delegates) {
|
||||
@@ -49,7 +49,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
this.delegates = delegates;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureRepositoryRestConfiguration(org.springframework.data.rest.core.config.RepositoryRestConfiguration)
|
||||
*/
|
||||
@@ -61,7 +61,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureConversionService(org.springframework.core.convert.support.ConfigurableConversionService)
|
||||
*/
|
||||
@@ -73,7 +73,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureExceptionHandlerExceptionResolver(org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver)
|
||||
*/
|
||||
@@ -85,7 +85,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureHttpMessageConverters(java.util.List)
|
||||
*/
|
||||
@@ -97,7 +97,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureJacksonObjectMapper(com.fasterxml.jackson.databind.ObjectMapper)
|
||||
*/
|
||||
@@ -109,7 +109,7 @@ class RepositoryRestConfigurerDelegate implements RepositoryRestConfigurer {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.config.RepositoryRestConfigurer#configureValidatingRepositoryEventListener(org.springframework.data.rest.core.event.ValidatingRepositoryEventListener)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -164,7 +164,7 @@ import com.fasterxml.jackson.datatype.jdk8.Jdk8Module;
|
||||
* <p/>
|
||||
* Any XML files located in the classpath under the {@literal META-INF/spring-data-rest/} path will be automatically
|
||||
* found and loaded into this {@link org.springframework.context.ApplicationContext}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Jon Brisbin
|
||||
* @author Greg Turnquist
|
||||
@@ -199,7 +199,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
super(context, conversionService);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.beans.factory.BeanClassLoaderAware#setBeanClassLoader(java.lang.ClassLoader)
|
||||
*/
|
||||
@@ -208,7 +208,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
this.beanClassLoader = classLoader;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.beans.factory.InitializingBean#afterPropertiesSet()
|
||||
*/
|
||||
@@ -316,7 +316,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
/**
|
||||
* {@link org.springframework.beans.factory.config.BeanPostProcessor} to turn beans annotated as
|
||||
* {@link org.springframework.data.rest.repository.annotation.RepositoryEventHandler}s.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -326,7 +326,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* For merging incoming objects materialized from JSON with existing domain objects loaded from the repository.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
@@ -338,7 +338,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
/**
|
||||
* Turns an {@link javax.servlet.http.HttpServletRequest} into a
|
||||
* {@link org.springframework.http.server.ServerHttpRequest}.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -348,7 +348,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* A convenience resolver that pulls together all the information needed to service a request.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -388,7 +388,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
/**
|
||||
* A special {@link org.springframework.hateoas.EntityLinks} implementation that takes repository and current
|
||||
* configuration into account when generating links.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
@@ -404,7 +404,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* Reads incoming JSON into an entity.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -417,7 +417,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* Turns a domain class into a {@link org.springframework.data.rest.webmvc.json.JsonSchema}.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -430,7 +430,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* The {@link MessageSourceAccessor} to provide messages for {@link ResourceDescription}s being rendered.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -456,7 +456,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* The Jackson {@link ObjectMapper} used internally.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -474,7 +474,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* The {@link HttpMessageConverter} used by Spring MVC to read and write JSON data.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -545,7 +545,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* The {@link HttpMessageConverter} used to create {@literal text/uri-list} responses.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Bean
|
||||
@@ -571,7 +571,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
/**
|
||||
* Special {@link org.springframework.web.servlet.HandlerAdapter} that only recognizes handler methods defined in the
|
||||
* provided controller classes.
|
||||
*
|
||||
*
|
||||
* @param resourceProcessors {@link ResourceProcessor}s available in the {@link ApplicationContext}.
|
||||
* @return
|
||||
*/
|
||||
@@ -645,7 +645,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* Jackson module responsible for intelligently serializing and deserializing JSON that corresponds to an entity.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
protected Module persistentEntityJackson2Module() {
|
||||
@@ -683,7 +683,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
return new DefaultExcerptProjector(projectionFactory, resourceMappings());
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter#extendHandlerExceptionResolvers(java.util.List)
|
||||
*/
|
||||
@@ -746,7 +746,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
return new AlpsJsonHttpMessageConverter(alpsConverter());
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.web.config.HateoasAwareSpringDataWebConfiguration#pageableResolver()
|
||||
*/
|
||||
@@ -763,7 +763,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
return resolver;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.web.config.HateoasAwareSpringDataWebConfiguration#sortResolver()
|
||||
*/
|
||||
@@ -914,7 +914,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
// HAL Browser
|
||||
//
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter#addResourceHandlers(org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry)
|
||||
*/
|
||||
@@ -940,7 +940,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResourceSupportHttpMessageConverter} with the given order.
|
||||
*
|
||||
*
|
||||
* @param order the order for the {@link HttpMessageConverter}.
|
||||
*/
|
||||
public ResourceSupportHttpMessageConverter(int order) {
|
||||
@@ -948,7 +948,7 @@ public class RepositoryRestMvcConfiguration extends HateoasAwareSpringDataWebCon
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.core.Ordered#getOrder()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2014 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -33,7 +33,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to create {@link ResourceMetadata} instances.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -46,7 +46,7 @@ public class ResourceMetadataHandlerMethodArgumentResolver implements HandlerMet
|
||||
/**
|
||||
* Creates a new {@link ResourceMetadataHandlerMethodArgumentResolver} for the given {@link Repositories} and
|
||||
* {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param mappings must not be {@literal null}.
|
||||
* @param baseUri must not be {@literal null}.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -33,7 +33,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to create {@link RootResourceInformation} for injection into Spring MVC
|
||||
* controller methods.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -46,7 +46,7 @@ public class RootResourceInformationHandlerMethodArgumentResolver implements Han
|
||||
/**
|
||||
* Creates a new {@link RootResourceInformationHandlerMethodArgumentResolver} using the given {@link Repositories},
|
||||
* {@link RepositoryInvokerFactory} and {@link ResourceMetadataHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param invokerFactory must not be {@literal null}.
|
||||
* @param resourceMetadataResolver must not be {@literal null}.
|
||||
@@ -95,7 +95,7 @@ public class RootResourceInformationHandlerMethodArgumentResolver implements Han
|
||||
/**
|
||||
* Potentially customize the given {@link RepositoryInvoker} for the given domain type. Default implementations simply
|
||||
* returns the given invoker as is.
|
||||
*
|
||||
*
|
||||
* @param parameter must not be {@literal null}.
|
||||
* @param invoker will never be {@literal null}.
|
||||
* @param domainType will never be {@literal null}.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2014 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -38,7 +38,7 @@ import org.springframework.util.StringUtils;
|
||||
/**
|
||||
* {@link Converter} to render all {@link Link}s contained in a {@link ResourceSupport} as {@code text/uri-list} and
|
||||
* parse a request of that media type back into a {@link ResourceSupport} instance.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Greg Turnquist
|
||||
* @author Oliver Gierke
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -57,7 +57,7 @@ import com.fasterxml.jackson.databind.node.ObjectNode;
|
||||
* Component to apply an {@link ObjectNode} to an existing domain object. This is effectively a best-effort workaround
|
||||
* for Jackson's inability to apply a (partial) JSON document to an existing object in a deeply nested way. We manually
|
||||
* detect nested objects, lookup the original value and apply the merge recursively.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Mark Paluch
|
||||
* @author Craig Andrews
|
||||
@@ -72,7 +72,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Reads the given input stream into an {@link ObjectNode} and applies that to the given existing instance.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
* @param mapper must not be {@literal null}.
|
||||
@@ -93,7 +93,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Reads the given source node onto the given target object and applies PUT semantics, i.e. explicitly
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
* @param mapper
|
||||
@@ -122,7 +122,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Merges the state of given source object onto the target one preserving PUT semantics.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @param target can be {@literal null}.
|
||||
* @param mapper must not be {@literal null}.
|
||||
@@ -156,7 +156,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Copies the unmapped properties of the given {@link MappedProperties} from the source object to the target instance.
|
||||
*
|
||||
*
|
||||
* @param properties must not be {@literal null}.
|
||||
* @param source must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
@@ -194,7 +194,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Merges the given {@link ObjectNode} onto the given object.
|
||||
*
|
||||
*
|
||||
* @param root must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
* @param mapper must not be {@literal null}.
|
||||
@@ -286,7 +286,7 @@ public class DomainObjectReader {
|
||||
* Handles the given {@link JsonNode} by treating it as {@link ArrayNode} and the given source value as
|
||||
* {@link Collection}-like value. Looks up the actual type to handle from the potentially available first element,
|
||||
* falling back to component type lookup on the given type.
|
||||
*
|
||||
*
|
||||
* @param node must not be {@literal null}.
|
||||
* @param source must not be {@literal null}.
|
||||
* @param mapper must not be {@literal null}.
|
||||
@@ -307,7 +307,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Applies the diff handling to {@link ArrayNode}s, potentially recursing into nested ones.
|
||||
*
|
||||
*
|
||||
* @param array the source {@link ArrayNode}m, must not be {@literal null}.
|
||||
* @param collection the actual collection values, must not be {@literal null}.
|
||||
* @param mapper the {@link ObjectMapper} to use, must not be {@literal null}.
|
||||
@@ -358,7 +358,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Merges nested {@link Map} values for the given source {@link Map}, the {@link ObjectNode} and {@link ObjectMapper}.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @param node must not be {@literal null}.
|
||||
* @param mapper must not be {@literal null}.
|
||||
@@ -491,7 +491,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Returns the given source instance as {@link Collection} or creates a new one for the given type.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @param type must not be {@literal null} in case {@code source} is null.
|
||||
* @return
|
||||
@@ -514,7 +514,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Surrounds the given source {@link String} with quotes so that they represent a valid JSON String.
|
||||
*
|
||||
*
|
||||
* @param source can be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -524,7 +524,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* Returns the raw type of the given {@link TypeInformation} or {@link Object} as fallback.
|
||||
*
|
||||
*
|
||||
* @param type can be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -536,7 +536,7 @@ public class DomainObjectReader {
|
||||
* Returns the type to read for the given value and default type. The type will be defaulted to {@link Object} if
|
||||
* missing. If the given value's type is different from the given default (i.e. more concrete) the value's type will
|
||||
* be used.
|
||||
*
|
||||
*
|
||||
* @param value can be {@literal null}.
|
||||
* @param type can be {@literal null}.
|
||||
* @return
|
||||
@@ -562,7 +562,7 @@ public class DomainObjectReader {
|
||||
/**
|
||||
* {@link SimpleAssociationHandler} that skips linkable associations and forwards handling for all other ones to the
|
||||
* delegate {@link SimplePropertyHandler}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@@ -588,7 +588,7 @@ public class DomainObjectReader {
|
||||
|
||||
/**
|
||||
* {@link SimplePropertyHandler} to merge the states of the given objects.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private class MergingPropertyHandler implements SimplePropertyHandler {
|
||||
@@ -601,7 +601,7 @@ public class DomainObjectReader {
|
||||
/**
|
||||
* Creates a new {@link MergingPropertyHandler} for the given source, target, {@link PersistentEntity} and
|
||||
* {@link ObjectMapper}.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @param target must not be {@literal null}.
|
||||
* @param entity must not be {@literal null}.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -39,7 +39,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
|
||||
/**
|
||||
* Creates a new {@link EnumTranslator} using the given {@link MessageSourceAccessor}.
|
||||
*
|
||||
*
|
||||
* @param messageSourceAccessor must not be {@literal null}.
|
||||
*/
|
||||
public EnumTranslator(MessageSourceAccessor messageSourceAccessor) {
|
||||
@@ -51,7 +51,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
this.parseEnumNameAsFallback = true;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.core.config.EnumTranslationConfiguration#setEnableDefaultTranslation(boolean)
|
||||
*/
|
||||
@@ -60,7 +60,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
this.enableDefaultTranslation = enableDefaultTranslation;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.core.config.EnumTranslationConfiguration#setParseEnumNameAsFallback(boolean)
|
||||
*/
|
||||
@@ -73,7 +73,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
* Resolves the given enum value into a {@link String} consulting the configured {@link MessageSourceAccessor}
|
||||
* potentially falling back to the default translation if configured. Returning the plain enum name if no resolution
|
||||
* applies.
|
||||
*
|
||||
*
|
||||
* @param value must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -104,7 +104,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
/**
|
||||
* Parses the given source text into the corresponding enum value using the configured {@link MessageSourceAccessor}
|
||||
* potentially falling back to the default translation or the plain enum name if configured.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param text can be {@literal null}
|
||||
* @return the resolved enum or {@literal null} if the resolution failed.
|
||||
@@ -136,7 +136,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
/**
|
||||
* Resolves the given {@link String} text into an enum value of the given type potentially trying to resolve it
|
||||
* through the configured {@link MessageSourceAccessor}.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param text must not be {@literal null} or empty.
|
||||
* @param resolve whether to resolve the source {@link String} through the message source.
|
||||
@@ -159,7 +159,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
|
||||
/**
|
||||
* Renders a default translation for the given enum (capitalized, lower case, underscores replaced by spaces).
|
||||
*
|
||||
*
|
||||
* @param value must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -169,7 +169,7 @@ public class EnumTranslator implements EnumTranslationConfiguration {
|
||||
|
||||
/**
|
||||
* Tries to obtain an enum value assuming the given text is a default translation of the enum name.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param text must not be {@literal null} or empty.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2016 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -26,7 +26,7 @@ import com.fasterxml.jackson.datatype.joda.JodaModule;
|
||||
|
||||
/**
|
||||
* Helper class to register datatype modules based on their presence in the classpath.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016-2017 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -59,7 +59,7 @@ public class JacksonMappingAwareSortTranslator {
|
||||
/**
|
||||
* Creates a new {@link JacksonMappingAwareSortTranslator} for the given {@link ObjectMapper}, {@link Repositories},
|
||||
* {@link DomainClassResolver} and {@link PersistentEntities}.
|
||||
*
|
||||
*
|
||||
* @param objectMapper must not be {@literal null}.
|
||||
* @param repositories must not be {@literal null}.
|
||||
* @param domainClassResolver must not be {@literal null}.
|
||||
@@ -237,7 +237,7 @@ public class JacksonMappingAwareSortTranslator {
|
||||
/**
|
||||
* Creates the initial {@link TypedSegment} given {@link PersistentEntities}, {@link ObjectMapper} and
|
||||
* {@link PersistentEntity}.
|
||||
*
|
||||
*
|
||||
* @param persistentEntities must not be {@literal null}.
|
||||
* @param objectMapper must not be {@literal null}.
|
||||
* @param rootEntity the initial entity to start mapping from, must not be {@literal null}.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -40,7 +40,7 @@ import com.fasterxml.jackson.databind.ser.DefaultSerializerProvider;
|
||||
|
||||
/**
|
||||
* Value object to abstract Jackson based bean metadata of a given type.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
*/
|
||||
@@ -53,7 +53,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Creates a new {@link JacksonMetadata} instance for the given {@link ObjectMapper} and type.
|
||||
*
|
||||
*
|
||||
* @param mapper must not be {@literal null}.
|
||||
* @param type must not be {@literal null}.
|
||||
*/
|
||||
@@ -79,7 +79,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Returns the {@link BeanPropertyDefinition} for the given {@link PersistentProperty}.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return can be {@literal null} in case there's no Jackson property to be exposed for the given
|
||||
* {@link PersistentProperty}.
|
||||
@@ -93,7 +93,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Returns the fallback {@link ResourceDescription} to be used for the given {@link BeanPropertyDefinition}.
|
||||
*
|
||||
*
|
||||
* @param ownerMetadata must not be {@literal null}.
|
||||
* @param definition must not be {@literal null}.
|
||||
* @return
|
||||
@@ -113,7 +113,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Check if a given property for a type is available to be exported, i.e. serialized via Jackson.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -126,7 +126,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Returns whether the backing type is considered a Jackson value type.
|
||||
*
|
||||
*
|
||||
* @return the isValue
|
||||
*/
|
||||
public boolean isValueType() {
|
||||
@@ -135,7 +135,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Returns whether the given {@link PersistentProperty} is considered read-only by Jackson.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -147,7 +147,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Returns the {@link JsonSerializer} for the given type, or {@literal null} if none available.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -173,7 +173,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Iterable#iterator()
|
||||
*/
|
||||
@@ -184,7 +184,7 @@ public class JacksonMetadata implements Iterable<BeanPropertyDefinition> {
|
||||
|
||||
/**
|
||||
* Finds the {@link BeanPropertyDefinition} for the given {@link PersistentProperty} within the given definitions.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @param definitions must not be {@literal null}.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015-2016 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -42,7 +42,7 @@ import com.fasterxml.jackson.databind.ser.std.StdSerializer;
|
||||
|
||||
/**
|
||||
* Custom Spring Data REST Jackson serializers.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.4
|
||||
* @soundtrack Wallis Bird - I Could Be Your Man (Yeah! Wallis Bird Live 2007-2014)
|
||||
@@ -53,7 +53,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a new {@link JacksonSerializers} with the given {@link EnumTranslator}.
|
||||
*
|
||||
*
|
||||
* @param translator must not be {@literal null}.
|
||||
*/
|
||||
public JacksonSerializers(EnumTranslator translator) {
|
||||
@@ -83,7 +83,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a new {@link EnumTranslatingSerializer} using the given {@link EnumTranslator}.
|
||||
*
|
||||
*
|
||||
* @param translator must not be {@literal null}.
|
||||
*/
|
||||
public EnumTranslatingSerializer(EnumTranslator translator) {
|
||||
@@ -95,7 +95,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
this.translator = translator;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.ser.std.StdSerializer#serialize(java.lang.Object, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)
|
||||
*/
|
||||
@@ -104,7 +104,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
gen.writeString(translator.asText(value));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.json.JsonSchemaPropertyCustomizer#customize(org.springframework.data.rest.webmvc.json.JsonSchema.JsonSchemaProperty, org.springframework.data.util.TypeInformation)
|
||||
*/
|
||||
@@ -136,7 +136,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a new {@link EnumTranslatingDeserializer} using the given {@link EnumTranslator}.
|
||||
*
|
||||
*
|
||||
* @param translator must not be {@literal null}.
|
||||
*/
|
||||
public EnumTranslatingDeserializer(EnumTranslator translator) {
|
||||
@@ -146,7 +146,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
/**
|
||||
* Creates a new {@link EnumTranslatingDeserializer} using the given {@link EnumTranslator} and {@link BeanProperty}
|
||||
* .
|
||||
*
|
||||
*
|
||||
* @param translator must not be {@literal null}.
|
||||
* @param property can be {@literal null}.
|
||||
*/
|
||||
@@ -160,7 +160,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
this.property = property;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.deser.ContextualDeserializer#createContextual(com.fasterxml.jackson.databind.DeserializationContext, com.fasterxml.jackson.databind.BeanProperty)
|
||||
*/
|
||||
@@ -170,7 +170,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
return new EnumTranslatingDeserializer(translator, property);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonDeserializer#deserialize(com.fasterxml.jackson.core.JsonParser, com.fasterxml.jackson.databind.DeserializationContext)
|
||||
*/
|
||||
@@ -188,7 +188,7 @@ public class JacksonSerializers extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Returns the value types for containers or the original type otherwise.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -43,7 +43,7 @@ import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
|
||||
/**
|
||||
* Model class to render JSON schema documents.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -61,7 +61,7 @@ public class JsonSchema {
|
||||
/**
|
||||
* Creates a new {@link JsonSchema} instance for the given title, description, {@link AbstractJsonSchemaProperty}s and
|
||||
* {@link Definitions}.
|
||||
*
|
||||
*
|
||||
* @param title must not be {@literal null} or empty.
|
||||
* @param description can be {@literal null}.
|
||||
* @param properties must not be {@literal null}.
|
||||
@@ -109,7 +109,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Turns the given {@link TypeInformation} into a JSON Schema type string.
|
||||
*
|
||||
*
|
||||
* @param typeInformation
|
||||
* @return
|
||||
* @see <a href=
|
||||
@@ -138,7 +138,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Returns whether the given {@link TypeInformation} represents a date.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -171,7 +171,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Creates a new {@link Item} for the given {@link TypeInformation} and properties.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param properties must not be {@literal null}.
|
||||
*/
|
||||
@@ -205,7 +205,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Creates a new {@link PropertiesContainer} for the given {@link AbstractJsonSchemaProperty}s.
|
||||
*
|
||||
*
|
||||
* @param properties must not be {@literal null}.
|
||||
*/
|
||||
public PropertiesContainer(Collection<AbstractJsonSchemaProperty<?>> properties) {
|
||||
@@ -344,7 +344,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Configures the {@link JsonSchemaProperty} to reflect the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -356,7 +356,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Configures the {@link JsonSchemaProperty} to reflect the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -383,7 +383,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Configures the given {@link JsonSchemaFormat} to be exposed on the current {@link JsonSchemaProperty}.
|
||||
*
|
||||
*
|
||||
* @param format must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -397,7 +397,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Configures the {@link JsonSchemaProperty} to require the given regular expression as pattern.
|
||||
*
|
||||
*
|
||||
* @param regex must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -409,7 +409,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Configures the {@link JsonSchemaProperty} to require the given {@link Pattern}.
|
||||
*
|
||||
*
|
||||
* @param pattern must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -423,7 +423,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Turns the current {@link JsonSchemaProperty} into an association.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public JsonSchemaProperty asAssociation() {
|
||||
@@ -484,7 +484,7 @@ public class JsonSchema {
|
||||
|
||||
/**
|
||||
* Returns the current {@link EnumProperty} exposing the given values.
|
||||
*
|
||||
*
|
||||
* @param values must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -20,7 +20,7 @@ import org.springframework.data.util.TypeInformation;
|
||||
|
||||
/**
|
||||
* Callback interface to customize the {@link JsonSchemaProperty} created by default for a given type.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.4
|
||||
* @soundtrack Superflight - Four Sided Cube (Bellyjam)
|
||||
@@ -29,7 +29,7 @@ public interface JsonSchemaPropertyCustomizer {
|
||||
|
||||
/**
|
||||
* Returns the customized {@link JsonSchemaProperty} based on the given one and the given type.
|
||||
*
|
||||
*
|
||||
* @param property will never be {@literal null}.
|
||||
* @param type will never be {@literal null}.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -142,7 +142,7 @@ class MappedProperties {
|
||||
|
||||
/**
|
||||
* Returns all properties only known to Jackson.
|
||||
*
|
||||
*
|
||||
* @return the names of all properties that are not known to Spring Data but appear in the Jackson metamodel.
|
||||
*/
|
||||
public Iterable<String> getSpringDataUnmappedProperties() {
|
||||
@@ -162,7 +162,7 @@ class MappedProperties {
|
||||
|
||||
/**
|
||||
* Returns whether the given {@link PersistentProperty} is mapped, i.e. known to both Jackson and Spring Data.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -35,7 +35,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
* A resolved {@link Pageable} is post-processed by applying Jackson field-to-property mapping if it contains a
|
||||
* {@link Sort} instance. Customized fields are resolved to their property names. Unknown properties are removed from
|
||||
* {@link Sort}.
|
||||
*
|
||||
*
|
||||
* @author Mark Paluch
|
||||
* @author Oliver Gierke
|
||||
* @since 2.6
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -33,7 +33,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
* <p>
|
||||
* A resolved {@link Sort} is post-processed by applying Jackson field-to-property mapping. Customized fields are
|
||||
* resolved to their property names. Unknown properties are removed from {@link Sort}.
|
||||
*
|
||||
*
|
||||
* @author Mark Paluch
|
||||
* @author Oliver Gierke
|
||||
* @since 2.6
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2016 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -93,7 +93,7 @@ import com.fasterxml.jackson.databind.util.NameTransformer;
|
||||
|
||||
/**
|
||||
* Jackson 2 module to serialize and deserialize {@link PersistentEntityResource}s.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
@@ -108,7 +108,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityJackson2Module} using the given {@link ResourceMappings}, {@link Repositories}
|
||||
* , {@link RepositoryRestConfiguration}, {@link UriToEntityConverter} and {@link SelfLinkProvider}.
|
||||
*
|
||||
*
|
||||
* @param associations must not be {@literal null}.
|
||||
* @param entities must not be {@literal null}.
|
||||
* @param converter must not be {@literal null}.
|
||||
@@ -144,7 +144,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Custom {@link JsonSerializer} for {@link PersistentEntityResource}s to turn associations into {@link Link}s.
|
||||
* Delegates to standard {@link Resource} serialization afterwards.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@SuppressWarnings("serial")
|
||||
@@ -155,7 +155,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityResourceSerializer} using the given {@link PersistentEntities} and
|
||||
* {@link Associations}.
|
||||
*
|
||||
*
|
||||
* @param entities must not be {@literal null}.
|
||||
*/
|
||||
private PersistentEntityResourceSerializer(LinkCollector collector) {
|
||||
@@ -223,7 +223,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
|
||||
/**
|
||||
* {@link BeanSerializerModifier} to drop the property descriptors for associations.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@@ -234,7 +234,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
private final @NonNull NestedEntitySerializer nestedEntitySerializer;
|
||||
private final @NonNull LookupObjectSerializer lookupObjectSerializer;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.ser.BeanSerializerModifier#changeProperties(com.fasterxml.jackson.databind.SerializationConfig, com.fasterxml.jackson.databind.BeanDescription, java.util.List)
|
||||
*/
|
||||
@@ -298,7 +298,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Returns the {@link PersistentProperty} for the property with the given final name (the name that it will be
|
||||
* rendered under eventually).
|
||||
*
|
||||
*
|
||||
* @param finalName the output name the property will be rendered under.
|
||||
* @param entity the {@link PersistentEntity} to find the property on.
|
||||
* @param description the Jackson {@link BeanDescription}.
|
||||
@@ -337,7 +337,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.invoker = invoker;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.ser.std.StdSerializer#serialize(java.lang.Object, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)
|
||||
*/
|
||||
@@ -395,7 +395,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
* A {@link BeanDeserializerModifier} that registers a custom {@link UriStringDeserializer} for association properties
|
||||
* of {@link PersistentEntity}s. This allows to submit URIs for those properties in request payloads, so that
|
||||
* non-optional associations can be populated on resource creation.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@@ -406,7 +406,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
private final @NonNull UriToEntityConverter converter;
|
||||
private final @NonNull RepositoryInvokerFactory factory;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.deser.BeanDeserializerModifier#updateBuilder(com.fasterxml.jackson.databind.DeserializationConfig, com.fasterxml.jackson.databind.BeanDescription, com.fasterxml.jackson.databind.deser.BeanDeserializerBuilder)
|
||||
*/
|
||||
@@ -470,7 +470,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Custom {@link JsonDeserializer} to interpret {@link String} values as URIs and resolve them using a
|
||||
* {@link UriToEntityConverter}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Valentin Rentschler
|
||||
*/
|
||||
@@ -485,7 +485,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Creates a new {@link UriStringDeserializer} for the given {@link PersistentProperty} using the given
|
||||
* {@link UriToEntityConverter}.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @param converter must not be {@literal null}.
|
||||
*/
|
||||
@@ -497,7 +497,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.converter = converter;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonDeserializer#deserialize(com.fasterxml.jackson.core.JsonParser, com.fasterxml.jackson.databind.DeserializationContext)
|
||||
*/
|
||||
@@ -523,7 +523,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Deserialize by ignoring the {@link TypeDeserializer}, as URIs will either resolve to {@literal null} or a
|
||||
* concrete instance anyway.
|
||||
*
|
||||
*
|
||||
* @see com.fasterxml.jackson.databind.deser.std.StdDeserializer#deserializeWithType(com.fasterxml.jackson.core.JsonParser,
|
||||
* com.fasterxml.jackson.databind.DeserializationContext,
|
||||
* com.fasterxml.jackson.databind.jsontype.TypeDeserializer)
|
||||
@@ -546,7 +546,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* Creates a new {@link ProjectionSerializer} for the given {@link LinkCollector}, {@link ResourceMappings} whether
|
||||
* to be in unwrapping mode or not.
|
||||
*
|
||||
*
|
||||
* @param collector must not be {@literal null}.
|
||||
* @param mappings must not be {@literal null}.
|
||||
* @param invoker must not be {@literal null}.
|
||||
@@ -563,7 +563,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.unwrapping = unwrapping;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.ser.std.StdSerializer#serialize(java.lang.Object, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)
|
||||
*/
|
||||
@@ -585,7 +585,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonSerializer#isUnwrappingSerializer()
|
||||
*/
|
||||
@@ -594,7 +594,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
return unwrapping;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonSerializer#unwrappingSerializer(com.fasterxml.jackson.databind.util.NameTransformer)
|
||||
*/
|
||||
@@ -605,7 +605,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a {@link ProjectionResource} for the given {@link TargetAware}.
|
||||
*
|
||||
*
|
||||
* @param value must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -658,7 +658,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ProjectionResourceContentSerializer}.
|
||||
*
|
||||
*
|
||||
* @param unwrapping whether to expose the unwrapping state.
|
||||
*/
|
||||
public ProjectionResourceContentSerializer(boolean unwrapping) {
|
||||
@@ -667,7 +667,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.unwrapping = unwrapping;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.ser.std.StdSerializer#serialize(java.lang.Object, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)
|
||||
*/
|
||||
@@ -681,7 +681,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
serialize(value.getProjection(), jgen, provider);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonSerializer#isUnwrappingSerializer()
|
||||
*/
|
||||
@@ -690,7 +690,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
return unwrapping;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonSerializer#unwrappingSerializer(com.fasterxml.jackson.databind.util.NameTransformer)
|
||||
*/
|
||||
@@ -703,7 +703,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
/**
|
||||
* {@link ValueInstantiator} to create collection or map instances based on the type of the configured
|
||||
* {@link PersistentProperty}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
private static class CollectionValueInstantiator extends ValueInstantiator {
|
||||
@@ -712,7 +712,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
|
||||
/**
|
||||
* Creates a new {@link CollectionValueInstantiator} for the given {@link PersistentProperty}.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null} and must be a collection.
|
||||
*/
|
||||
public CollectionValueInstantiator(PersistentProperty<?> property) {
|
||||
@@ -723,7 +723,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.property = property;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.deser.ValueInstantiator#getValueTypeDesc()
|
||||
*/
|
||||
@@ -732,7 +732,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
return property.getType().getName();
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.deser.ValueInstantiator#createUsingDefault(com.fasterxml.jackson.databind.DeserializationContext)
|
||||
*/
|
||||
@@ -757,7 +757,7 @@ public class PersistentEntityJackson2Module extends SimpleModule {
|
||||
this.invoker = factory.getInvokerFor(_valueClass);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see com.fasterxml.jackson.databind.JsonDeserializer#deserialize(com.fasterxml.jackson.core.JsonParser, com.fasterxml.jackson.databind.DeserializationContext)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2016 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -66,7 +66,7 @@ import com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition;
|
||||
|
||||
/**
|
||||
* Converter to create {@link JsonSchema} instances for {@link PersistentEntity}s.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
* @author Greg Turnquist
|
||||
@@ -88,7 +88,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityToJsonSchemaConverter} for the given {@link PersistentEntities} and
|
||||
* {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @param entities must not be {@literal null}.
|
||||
* @param mappings must not be {@literal null}.
|
||||
* @param accessor must not be {@literal null}.
|
||||
@@ -138,7 +138,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
/**
|
||||
* Converts the given type into a {@link JsonSchema} instance.
|
||||
*
|
||||
*
|
||||
* @param domainType must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -314,7 +314,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
/**
|
||||
* Creates a new {@link JsonSchemaPropertyRegistrar} using the given {@link JacksonMetadata}.
|
||||
*
|
||||
*
|
||||
* @param metadata must not be {@literal null}.
|
||||
*/
|
||||
public JsonSchemaPropertyRegistrar(JacksonMetadata metadata) {
|
||||
@@ -361,7 +361,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
return new JsonSchemaPropertyCustomizer() {
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.json.JsonSchemaPropertyCustomizer#customize(org.springframework.data.rest.webmvc.json.JsonSchema.JsonSchemaProperty, org.springframework.data.util.TypeInformation)
|
||||
*/
|
||||
@@ -394,7 +394,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResolvableProperty} for the given {@link BeanPropertyDefinition}.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
*/
|
||||
public ResolvableProperty(BeanPropertyDefinition property) {
|
||||
@@ -427,7 +427,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
/**
|
||||
* Creates a new {@link ResolvableType} for the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
*/
|
||||
public ResolvableType(Class<?> type) {
|
||||
@@ -539,14 +539,14 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
|
||||
/**
|
||||
* Creates a new {@link DefaultingMessageSourceResolvable} for the given delegate {@link MessageSourceResolvable}.
|
||||
*
|
||||
*
|
||||
* @param delegate must not be {@literal null}.
|
||||
*/
|
||||
public DefaultingMessageSourceResolvable(MessageSourceResolvable delegate) {
|
||||
this.delegate = delegate;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.context.MessageSourceResolvable#getArguments()
|
||||
*/
|
||||
@@ -555,7 +555,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
return delegate.getArguments();
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.context.MessageSourceResolvable#getCodes()
|
||||
*/
|
||||
@@ -564,7 +564,7 @@ public class PersistentEntityToJsonSchemaConverter implements ConditionalGeneric
|
||||
return delegate.getCodes();
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.context.MessageSourceResolvable#getDefaultMessage()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -113,7 +113,7 @@ class WrappedProperties {
|
||||
|
||||
/**
|
||||
* This class resolves {@code @JsonUnwrapped} field names to a list of involved {@link PersistentProperty properties}.
|
||||
*
|
||||
*
|
||||
* @author Mark Paluch
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -17,4 +17,4 @@
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
package org.springframework.data.rest.webmvc.json;
|
||||
package org.springframework.data.rest.webmvc.json;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -18,7 +18,7 @@ package org.springframework.data.rest.webmvc.json.patch;
|
||||
/**
|
||||
* Operation to add a new value to the given "path". Will throw a {@link PatchException} if the path is invalid or if
|
||||
* the given value is not assignable to the given path.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -26,7 +26,7 @@ class AddOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the add operation
|
||||
*
|
||||
*
|
||||
* @param path The path where the value will be added. (e.g., '/foo/bar/4')
|
||||
* @param value The value to add.
|
||||
*/
|
||||
@@ -47,7 +47,7 @@ class AddOperation extends PatchOperation {
|
||||
path.bindTo(type).addValue(targetObject, evaluateValueFromTarget(targetObject, type));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.json.patch.PatchOperation#evaluateValueFromTarget(java.lang.Object, java.lang.Class)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -35,7 +35,7 @@ import lombok.RequiredArgsConstructor;
|
||||
* In light of this, it's probably a good idea to perform a "replace" after a "copy" to set the ID property (which may
|
||||
* or may not be "id").
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -45,7 +45,7 @@ class CopyOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the copy operation
|
||||
*
|
||||
*
|
||||
* @param path The path to copy the source value to. (e.g., '/foo/bar/4')
|
||||
* @param from The source path from which a value will be copied. (e.g., '/foo/bar/5')
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -23,7 +23,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
|
||||
/**
|
||||
* {@link LateObjectEvaluator} implementation that assumes values represented as JSON objects.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Trosien
|
||||
* @author Oliver Gierke
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -28,7 +28,7 @@ import com.fasterxml.jackson.databind.node.ArrayNode;
|
||||
|
||||
/**
|
||||
* Convert {@link JsonNode}s containing JSON Patch to/from {@link Patch} objects.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
* @author Mathias Düsterhöft
|
||||
@@ -41,7 +41,7 @@ public class JsonPatchPatchConverter implements PatchConverter<JsonNode> {
|
||||
|
||||
/**
|
||||
* Constructs a {@link Patch} object given a JsonNode.
|
||||
*
|
||||
*
|
||||
* @param jsonNode a JsonNode containing the JSON Patch
|
||||
* @return a {@link Patch}
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -29,7 +29,7 @@ package org.springframework.data.rest.webmvc.json.patch;
|
||||
* This interface allows for pluggable evaluation of values, allowing {@link Patch} to remain independent of any
|
||||
* specific patch representation.
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
*/
|
||||
interface LateObjectEvaluator {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -29,7 +29,7 @@ import lombok.RequiredArgsConstructor;
|
||||
* on the values of each item in the list. When the same list resource is retrieved again later, the order will again be
|
||||
* decided by the query, effectively undoing any previous move operation.
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -39,7 +39,7 @@ class MoveOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the move operation.
|
||||
*
|
||||
*
|
||||
* @param path The path to move the source value to. (e.g., '/foo/bar/4')
|
||||
* @param from The source path from which a value will be moved. (e.g., '/foo/bar/5')
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -25,7 +25,7 @@ import java.util.List;
|
||||
* This class (and {@link PatchOperation} capture the definition of a patch, but are not coupled to any specific patch
|
||||
* representation.
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -51,7 +51,7 @@ public class Patch {
|
||||
/**
|
||||
* Applies the Patch to a given Object graph. Makes a copy of the given object so that it will remain unchanged after
|
||||
* application of the patch and in case any errors occur while performing the patch.
|
||||
*
|
||||
*
|
||||
* @param in The object graph to apply the patch to.
|
||||
* @param type The object type.
|
||||
* @param <T> the object type.
|
||||
@@ -70,7 +70,7 @@ public class Patch {
|
||||
/**
|
||||
* Applies the Patch to a given List of objects. Makes a copy of the given list so that it will remain unchanged after
|
||||
* application of the patch and in case any errors occur while performing the patch.
|
||||
*
|
||||
*
|
||||
* @param in The list to apply the patch to.
|
||||
* @param type The list's generic type.
|
||||
* @param <T> the list's generic type.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -27,7 +27,7 @@ import com.fasterxml.jackson.databind.JsonNode;
|
||||
* For example, if the {@link Patch} is to be represented as JSON Patch, the representation type could be
|
||||
* {@link JsonNode} or some other JSON library's type that holds a JSON document.
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
* @param <T> A type holding a representation of the patch. For example, a JsonNode if working with JSON Patch.
|
||||
@@ -36,7 +36,7 @@ public interface PatchConverter<T> {
|
||||
|
||||
/**
|
||||
* Convert a patch document representation to a {@link Patch}.
|
||||
*
|
||||
*
|
||||
* @param patchRepresentation the representation of a patch.
|
||||
* @return the {@link Patch} object that the document represents.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -17,7 +17,7 @@ package org.springframework.data.rest.webmvc.json.patch;
|
||||
|
||||
/**
|
||||
* Exception thrown if an error occurs in the course of applying a Patch.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -20,7 +20,7 @@ import lombok.RequiredArgsConstructor;
|
||||
|
||||
/**
|
||||
* Abstract base class representing and providing support methods for patch operations.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Mathias Düsterhöft
|
||||
* @author Oliver Gierke
|
||||
@@ -34,7 +34,7 @@ public abstract class PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the operation.
|
||||
*
|
||||
*
|
||||
* @param op the operation name. (e.g., 'move')
|
||||
* @param path the path to perform the operation on. (e.g., '/1/description')
|
||||
*/
|
||||
@@ -44,7 +44,7 @@ public abstract class PatchOperation {
|
||||
|
||||
/**
|
||||
* Performs late-value evaluation on the operation value if the value is a {@link LateObjectEvaluator}.
|
||||
*
|
||||
*
|
||||
* @param targetObject the target object, used as assistance in determining the evaluated object's type.
|
||||
* @param entityType the entityType
|
||||
* @param <T> the entity type
|
||||
@@ -61,7 +61,7 @@ public abstract class PatchOperation {
|
||||
|
||||
/**
|
||||
* Perform the operation in the given target object.
|
||||
*
|
||||
*
|
||||
* @param target the target of the operation, must not be {@literal null}.
|
||||
* @param type must not be {@literal null}.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -18,7 +18,7 @@ package org.springframework.data.rest.webmvc.json.patch;
|
||||
/**
|
||||
* Operation that removes the value at the given path. Will throw a {@link PatchException} if the given path isn't valid
|
||||
* or if the path is non-nullable.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -26,7 +26,7 @@ class RemoveOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the remove operation
|
||||
*
|
||||
*
|
||||
* @param path The path of the value to be removed. (e.g., '/foo/bar/4')
|
||||
*/
|
||||
private RemoveOperation(SpelPath path) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -20,7 +20,7 @@ import lombok.RequiredArgsConstructor;
|
||||
|
||||
/**
|
||||
* Operation that replaces the value at the given path with a new value.
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -28,7 +28,7 @@ class ReplaceOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the replace operation
|
||||
*
|
||||
*
|
||||
* @param path The path whose value is to be replaced. (e.g., '/foo/bar/4')
|
||||
* @param value The value that will replace the current path value.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2017 the original author or authors.
|
||||
* Copyright 2017-2018 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.
|
||||
@@ -41,7 +41,7 @@ import org.springframework.util.ConcurrentReferenceHashMap;
|
||||
|
||||
/**
|
||||
* Value object to represent a SpEL-backed patch path.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@RequiredArgsConstructor(access = AccessLevel.PRIVATE)
|
||||
@@ -64,7 +64,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns a {@link SpelPath} for the given source.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -74,7 +74,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns a {@link TypedSpelPath} binding the expression to the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -87,7 +87,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns the leaf type of the underlying expression or the given type
|
||||
*
|
||||
*
|
||||
* @param type
|
||||
* @return
|
||||
*/
|
||||
@@ -100,7 +100,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns whether the current path represents an append path, i.e. is supposed to append to collection.
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public boolean isAppend() {
|
||||
@@ -111,7 +111,7 @@ class SpelPath {
|
||||
return SpelPath.of(path.substring(0, path.lastIndexOf('/')));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Object#toString()
|
||||
*/
|
||||
@@ -120,7 +120,7 @@ class SpelPath {
|
||||
return path;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Object#equals(java.lang.Object)
|
||||
*/
|
||||
@@ -140,7 +140,7 @@ class SpelPath {
|
||||
return this.path.equals(that.path);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Object#hashCode()
|
||||
*/
|
||||
@@ -229,7 +229,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns the {@link TypedSpelPath} for the given {@link SpelPath} and type.
|
||||
*
|
||||
*
|
||||
* @param path must not be {@literal null}.
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
@@ -244,7 +244,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns the value pointed to by the current path with the given target object.
|
||||
*
|
||||
*
|
||||
* @param target must not be {@literal null}.
|
||||
* @return can be {@literal null}.
|
||||
*/
|
||||
@@ -262,7 +262,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Sets the given value on the given target object.
|
||||
*
|
||||
*
|
||||
* @param target must not be {@literal null}.
|
||||
* @param value can be {@literal null}.
|
||||
*/
|
||||
@@ -275,7 +275,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Returns the type of the expression target based on the given root.
|
||||
*
|
||||
*
|
||||
* @param root must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -288,7 +288,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Copies the value pointed to by the given path within the given source object to the current expression target.
|
||||
*
|
||||
*
|
||||
* @param path the {@link SpelPath} to look the value up from, must not be {@literal null}.
|
||||
* @param source the source object to look the value up from, must not be {@literal null}.
|
||||
* @return
|
||||
@@ -305,7 +305,7 @@ class SpelPath {
|
||||
/**
|
||||
* Moves the value pointed to by the given path within the given source object to the current expression target and
|
||||
* removes the value from its original position.
|
||||
*
|
||||
*
|
||||
* @param path the {@link SpelPath} to look the value up from, must not be {@literal null}.
|
||||
* @param source the source object to look the value up from, must not be {@literal null}.
|
||||
* @return
|
||||
@@ -320,7 +320,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Removes the value pointed to by the current path within the given target.
|
||||
*
|
||||
*
|
||||
* @param target must not be {@literal null}.
|
||||
* @return the original value that was just removed.
|
||||
*/
|
||||
@@ -351,7 +351,7 @@ class SpelPath {
|
||||
/**
|
||||
* Adds a value to the operation's path. If the path references a list index, the value is added to the list at the
|
||||
* given index. If the path references an object property, the property is set to the value.
|
||||
*
|
||||
*
|
||||
* @param target The target object.
|
||||
* @param value The value to add.
|
||||
*/
|
||||
@@ -410,7 +410,7 @@ class SpelPath {
|
||||
|
||||
/**
|
||||
* Verifies that the given path exists on the given type. Skips collection index parts and append characters.
|
||||
*
|
||||
*
|
||||
* @param path must not be {@literal null} or empty.
|
||||
* @param type must not be {@literal null}.
|
||||
* @return the {@link PropertyPath} if the path could be resolved or {@link Optional#empty()} in case an empty path
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -31,7 +31,7 @@ import org.springframework.util.ObjectUtils;
|
||||
* If the value given matches the value given at the path, the operation completes as a no-op. On the other hand, if the
|
||||
* values do not match or if there are any errors interpreting the path, a {@link PatchException} will be thrown.
|
||||
* </p>
|
||||
*
|
||||
*
|
||||
* @author Craig Walls
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -39,7 +39,7 @@ class TestOperation extends PatchOperation {
|
||||
|
||||
/**
|
||||
* Constructs the test operation
|
||||
*
|
||||
*
|
||||
* @param path The path to test. (e.g., '/foo/bar/4')
|
||||
* @param value The value to test the path against.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -82,7 +82,7 @@ public class Associations {
|
||||
|
||||
/**
|
||||
* Returns the {@link ResourceMetadata} for the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -95,7 +95,7 @@ public class Associations {
|
||||
|
||||
/**
|
||||
* Returns whether the type of the given {@link PersistentProperty} is configured as lookup type.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -112,7 +112,7 @@ public class Associations {
|
||||
|
||||
/**
|
||||
* Returns whether the given {@link Association} is linkable.
|
||||
*
|
||||
*
|
||||
* @param association must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -125,7 +125,7 @@ public class Associations {
|
||||
|
||||
/**
|
||||
* Returns whether the given property is an association that is linkable.
|
||||
*
|
||||
*
|
||||
* @param property must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -30,7 +30,7 @@ import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
* {@link SimpleAssociationHandler} that will collect {@link Link}s for all linkable associations.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.1
|
||||
*/
|
||||
@@ -48,7 +48,7 @@ public class LinkCollectingAssociationHandler implements SimpleAssociationHandle
|
||||
/**
|
||||
* Creates a new {@link LinkCollectingAssociationHandler} for the given {@link PersistentEntities}, {@link Path} and
|
||||
* {@link Associations}.
|
||||
*
|
||||
*
|
||||
* @param entities must not be {@literal null}.
|
||||
* @param path must not be {@literal null}.
|
||||
* @param associations must not be {@literal null}.
|
||||
@@ -78,14 +78,14 @@ public class LinkCollectingAssociationHandler implements SimpleAssociationHandle
|
||||
|
||||
/**
|
||||
* Returns the links collected after the {@link Association} has been traversed.
|
||||
*
|
||||
*
|
||||
* @return the links
|
||||
*/
|
||||
public List<Link> getLinks() {
|
||||
return links;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.mapping.SimpleAssociationHandler#doWithAssociation(org.springframework.data.mapping.Association)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016-2017 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -48,7 +48,7 @@ public class NestedLinkCollectingAssociationHandler implements SimpleAssociation
|
||||
|
||||
private final @Getter List<Link> links = new ArrayList<Link>();
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.mapping.SimpleAssociationHandler#doWithAssociation(org.springframework.data.mapping.Association)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -21,14 +21,14 @@ import org.springframework.plugin.core.Plugin;
|
||||
|
||||
/**
|
||||
* SPI to allow the customization of how entity ids are exposed in URIs generated.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public interface BackendIdConverter extends Plugin<Class<?>> {
|
||||
|
||||
/**
|
||||
* Returns the id of the entity to be looked up eventually.
|
||||
*
|
||||
*
|
||||
* @param id the source id as it was parsed from the incoming request, will never be {@literal null}.
|
||||
* @param entityType the type of the object to be resolved, will never be {@literal null}.
|
||||
* @return must not be {@literal null}.
|
||||
@@ -37,7 +37,7 @@ public interface BackendIdConverter extends Plugin<Class<?>> {
|
||||
|
||||
/**
|
||||
* Returns the id to be used in the URI generated to point to an entity of the given type with the given id.
|
||||
*
|
||||
*
|
||||
* @param id the entity's id, will never be {@literal null}.
|
||||
* @param entityType the type of the entity to expose.
|
||||
* @return
|
||||
@@ -46,14 +46,14 @@ public interface BackendIdConverter extends Plugin<Class<?>> {
|
||||
|
||||
/**
|
||||
* The default {@link BackendIdConverter} that will simply use ids as they are.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public enum DefaultIdConverter implements BackendIdConverter {
|
||||
|
||||
INSTANCE;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.support.BackendIdConverter#fromRequestId(java.lang.String, java.lang.Class)
|
||||
*/
|
||||
@@ -62,7 +62,7 @@ public interface BackendIdConverter extends Plugin<Class<?>> {
|
||||
return id;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.support.BackendIdConverter#toRequestId(java.lang.Object, java.lang.Class)
|
||||
*/
|
||||
@@ -71,7 +71,7 @@ public interface BackendIdConverter extends Plugin<Class<?>> {
|
||||
return id.toString();
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.plugin.core.Plugin#supports(java.lang.Object)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -22,7 +22,7 @@ import java.lang.annotation.Target;
|
||||
|
||||
/**
|
||||
* Annotation to bind the backend id of an entity.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -34,7 +34,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to resolve entity ids for injection int handler method arguments annotated with
|
||||
* {@link BackendId}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class BackendIdHandlerMethodArgumentResolver implements HandlerMethodArgumentResolver {
|
||||
@@ -46,7 +46,7 @@ public class BackendIdHandlerMethodArgumentResolver implements HandlerMethodArgu
|
||||
/**
|
||||
* Creates a new {@link BackendIdHandlerMethodArgumentResolver} for the given {@link BackendIdConverter}s and
|
||||
* {@link ResourceMetadataHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @param idConverters the {@link BackendIdConverter}s registered in the system, must not be {@literal null}..
|
||||
* @param resourceMetadataResolver the resolver to obtain {@link ResourceMetadata} from, must not be {@literal null}.
|
||||
* @param baseUri must not be {@literal null}.
|
||||
@@ -63,7 +63,7 @@ public class BackendIdHandlerMethodArgumentResolver implements HandlerMethodArgu
|
||||
this.baseUri = baseUri;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
@@ -72,7 +72,7 @@ public class BackendIdHandlerMethodArgumentResolver implements HandlerMethodArgu
|
||||
return parameter.hasParameterAnnotation(BackendId.class);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#resolveArgument(org.springframework.core.MethodParameter, org.springframework.web.method.support.ModelAndViewContainer, org.springframework.web.context.request.NativeWebRequest, org.springframework.web.bind.support.WebDataBinderFactory)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -25,7 +25,7 @@ import org.springframework.util.Assert;
|
||||
/**
|
||||
* {@link DefaultedPageable} implementation of {@link ExcerptProjector} that uses the given {@link ProjectionFactory}
|
||||
* and considers the given {@link ResourceMappings}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.5
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -19,7 +19,7 @@ import org.springframework.data.domain.Pageable;
|
||||
|
||||
/**
|
||||
* Value object to capture a {@link Pageable} as well it is the default one configured.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class DefaultedPageable {
|
||||
@@ -29,7 +29,7 @@ public class DefaultedPageable {
|
||||
|
||||
/**
|
||||
* Creates a new {@link DefaultedPageable} with the given {@link Pageable} and default flag.
|
||||
*
|
||||
*
|
||||
* @param pageable can be {@literal null}.
|
||||
* @param isDefault
|
||||
*/
|
||||
@@ -41,7 +41,7 @@ public class DefaultedPageable {
|
||||
|
||||
/**
|
||||
* Returns the delegate {@link Pageable}.
|
||||
*
|
||||
*
|
||||
* @return can be {@literal null}.
|
||||
*/
|
||||
public Pageable getPageable() {
|
||||
@@ -50,7 +50,7 @@ public class DefaultedPageable {
|
||||
|
||||
/**
|
||||
* Returns whether the contained {@link Pageable} is the default one configured.
|
||||
*
|
||||
*
|
||||
* @return the isDefault
|
||||
*/
|
||||
public boolean isDefault() {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -28,7 +28,7 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
* {@link HandlerMethodArgumentResolver} to resolve {@link DefaultedPageable} if requested. Allows to find out whether
|
||||
* the resolved {@link Pageable} is logically identical to the fallback on configured on the delegate
|
||||
* {@link PageableHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class DefaultedPageableHandlerMethodArgumentResolver implements HandlerMethodArgumentResolver {
|
||||
@@ -38,7 +38,7 @@ public class DefaultedPageableHandlerMethodArgumentResolver implements HandlerMe
|
||||
/**
|
||||
* Creates a new {@link DefaultedPageableHandlerMethodArgumentResolver} delegating to the given
|
||||
* {@link PageableHandlerMethodArgumentResolver}.
|
||||
*
|
||||
*
|
||||
* @param resolver must not be {@literal null}.
|
||||
*/
|
||||
public DefaultedPageableHandlerMethodArgumentResolver(PageableHandlerMethodArgumentResolver resolver) {
|
||||
@@ -47,7 +47,7 @@ public class DefaultedPageableHandlerMethodArgumentResolver implements HandlerMe
|
||||
this.resolver = resolver;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#resolveArgument(org.springframework.core.MethodParameter, org.springframework.web.method.support.ModelAndViewContainer, org.springframework.web.context.request.NativeWebRequest, org.springframework.web.bind.support.WebDataBinderFactory)
|
||||
*/
|
||||
@@ -59,7 +59,7 @@ public class DefaultedPageableHandlerMethodArgumentResolver implements HandlerMe
|
||||
return new DefaultedPageable(pageable, resolver.isFallbackPageable(pageable));
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -32,7 +32,7 @@ import org.springframework.web.servlet.HandlerMapping;
|
||||
/**
|
||||
* A {@link HandlerMapping} that considers a {@link List} of delegates. It will keep on traversing the delegates in case
|
||||
* an {@link HttpMediaTypeNotAcceptableException} is thrown while trying to lookup the handler on a particular delegate.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @soundtrack Benny Greb - Stabila (Moving Parts)
|
||||
*/
|
||||
@@ -42,7 +42,7 @@ public class DelegatingHandlerMapping implements HandlerMapping, Ordered {
|
||||
|
||||
/**
|
||||
* Creates a new {@link DelegatingHandlerMapping} for the given delegates.
|
||||
*
|
||||
*
|
||||
* @param delegates must not be {@literal null}.
|
||||
*/
|
||||
public DelegatingHandlerMapping(List<HandlerMapping> delegates) {
|
||||
@@ -52,7 +52,7 @@ public class DelegatingHandlerMapping implements HandlerMapping, Ordered {
|
||||
this.delegates = delegates;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.core.Ordered#getOrder()
|
||||
*/
|
||||
@@ -61,7 +61,7 @@ public class DelegatingHandlerMapping implements HandlerMapping, Ordered {
|
||||
return Ordered.LOWEST_PRECEDENCE - 100;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.servlet.HandlerMapping#getHandler(javax.servlet.http.HttpServletRequest)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2015 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -30,7 +30,7 @@ import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
* A value object to represent ETags.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@EqualsAndHashCode
|
||||
@@ -42,7 +42,7 @@ public final class ETag {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ETag} from the given value.
|
||||
*
|
||||
*
|
||||
* @param value can be {@literal null}.
|
||||
*/
|
||||
private ETag(String value) {
|
||||
@@ -52,7 +52,7 @@ public final class ETag {
|
||||
/**
|
||||
* Creates a new {@link ETag} for the given {@link String} value. Falls back to {@link #NO_ETAG} in case
|
||||
* {@literal null} is provided.
|
||||
*
|
||||
*
|
||||
* @param value the source ETag value, must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -66,7 +66,7 @@ public final class ETag {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ETag} for the given {@link PersistentEntityResource}.
|
||||
*
|
||||
*
|
||||
* @param resource must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -79,7 +79,7 @@ public final class ETag {
|
||||
|
||||
/**
|
||||
* Creates a new {@link ETag} from the given {@link PersistentEntity} and target bean.
|
||||
*
|
||||
*
|
||||
* @param entity must not be {@literal null}.
|
||||
* @param bean must not be {@literal null}.
|
||||
* @return
|
||||
@@ -91,7 +91,7 @@ public final class ETag {
|
||||
/**
|
||||
* Verifies the ETag to be created for the given target bean with the current one and raises a
|
||||
* {@link ETagDoesntMatchException} in case they don't match.
|
||||
*
|
||||
*
|
||||
* @param entity must not be {@literal null}.
|
||||
* @param target can be {@literal null}.
|
||||
* @throws ETagDoesntMatchException in case the calculated {@link ETag} for the given bean does not match the current
|
||||
@@ -111,7 +111,7 @@ public final class ETag {
|
||||
/**
|
||||
* Returns whether the {@link ETag} matches the given {@link PersistentEntity} and target. A more dissenting way of
|
||||
* checking matches as it does not match if the ETag is {@link #NO_ETAG}.
|
||||
*
|
||||
*
|
||||
* @param entity must not be {@literal null}.
|
||||
* @param target can be {@literal null}.
|
||||
* @return
|
||||
@@ -127,7 +127,7 @@ public final class ETag {
|
||||
|
||||
/**
|
||||
* Adds the current {@link ETag} to the given headers.
|
||||
*
|
||||
*
|
||||
* @param headers must not be {@literal null}.
|
||||
* @return the {@link HttpHeaders} with the ETag header been set if the current {@link ETag} instance is not
|
||||
* {@link #NO_ETAG}.
|
||||
@@ -145,7 +145,7 @@ public final class ETag {
|
||||
return headers;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see java.lang.Object#toString()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -28,13 +28,13 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to resolve If-Match headers for optimistic locking handling {@link IfMatch}.
|
||||
*
|
||||
*
|
||||
* @author Pablo Lozano
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class ETagArgumentResolver implements HandlerMethodArgumentResolver {
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
@@ -43,7 +43,7 @@ public class ETagArgumentResolver implements HandlerMethodArgumentResolver {
|
||||
return parameter.getParameterType().equals(ETag.class);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#resolveArgument(org.springframework.core.MethodParameter, org.springframework.web.method.support.ModelAndViewContainer, org.springframework.web.context.request.NativeWebRequest, org.springframework.web.bind.support.WebDataBinderFactory)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -19,7 +19,7 @@ import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
* An exception being thrown in case the {@link ETag} calculated for a particular object does not match an expected one.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @see ETag#verify(org.springframework.data.mapping.PersistentEntity, Object)
|
||||
*/
|
||||
@@ -33,7 +33,7 @@ public class ETagDoesntMatchException extends RuntimeException {
|
||||
/**
|
||||
* Creates a new {@link ETagDoesntMatchException} for the given bean as well as the {@link ETag} it was expected to
|
||||
* match.
|
||||
*
|
||||
*
|
||||
* @param bean must not be {@literal null}.
|
||||
* @param expected must not be {@literal null}.
|
||||
*/
|
||||
@@ -48,7 +48,7 @@ public class ETagDoesntMatchException extends RuntimeException {
|
||||
|
||||
/**
|
||||
* Returns the bean not matching the {@link ETag}.
|
||||
*
|
||||
*
|
||||
* @return the bean
|
||||
*/
|
||||
public Object getBean() {
|
||||
@@ -57,7 +57,7 @@ public class ETagDoesntMatchException extends RuntimeException {
|
||||
|
||||
/**
|
||||
* Returns the {@link ETag} the bean was expected to match.
|
||||
*
|
||||
*
|
||||
* @return the expected
|
||||
*/
|
||||
public ETag getExpectedETag() {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2016 the original author or authors.
|
||||
* Copyright 2016-2018 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.
|
||||
@@ -17,7 +17,7 @@ package org.springframework.data.rest.webmvc.support;
|
||||
|
||||
/**
|
||||
* Interface for a component that can provide excerpt projections.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.5
|
||||
*/
|
||||
@@ -27,7 +27,7 @@ public interface ExcerptProjector {
|
||||
* Creates a excerpt projection for the given source. If no excerpt projection is available, the call will fall back
|
||||
* to the behavior of {@link #project(Object)}. If you completely wish to skip handling the object, check for the
|
||||
* presence of an excerpt projection using {@link #hasExcerptProjection(Class)}.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
@@ -35,7 +35,7 @@ public interface ExcerptProjector {
|
||||
|
||||
/**
|
||||
* Returns whether an excerpt projection has been registered for the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -27,14 +27,14 @@ import org.springframework.web.method.support.ModelAndViewContainer;
|
||||
/**
|
||||
* {@link HandlerMethodArgumentResolver} to provide {@link HttpMethod} instances for innjection into MVC controller
|
||||
* methods.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public enum HttpMethodHandlerMethodArgumentResolver implements HandlerMethodArgumentResolver {
|
||||
|
||||
INSTANCE;
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#supportsParameter(org.springframework.core.MethodParameter)
|
||||
*/
|
||||
@@ -43,7 +43,7 @@ public enum HttpMethodHandlerMethodArgumentResolver implements HandlerMethodArgu
|
||||
return HttpMethod.class.equals(parameter.getParameterType());
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.web.method.support.HandlerMethodArgumentResolver#resolveArgument(org.springframework.core.MethodParameter, org.springframework.web.method.support.ModelAndViewContainer, org.springframework.web.context.request.NativeWebRequest, org.springframework.web.bind.support.WebDataBinderFactory)
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2015 the original author or authors.
|
||||
* Copyright 2015-2018 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.
|
||||
@@ -22,7 +22,7 @@ import org.springframework.web.util.UriComponents;
|
||||
|
||||
/**
|
||||
* Interface to abstract the access of {@link TemplateVariables} for pagination and sorting.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @since 2.3
|
||||
*/
|
||||
@@ -30,7 +30,7 @@ public interface PagingAndSortingTemplateVariables extends UriComponentsContribu
|
||||
|
||||
/**
|
||||
* Returns the {@link TemplateVariables} for pagination.
|
||||
*
|
||||
*
|
||||
* @param parameter can be {@literal null}.
|
||||
* @param components must not be {@literal null}.
|
||||
* @return
|
||||
@@ -39,7 +39,7 @@ public interface PagingAndSortingTemplateVariables extends UriComponentsContribu
|
||||
|
||||
/**
|
||||
* Returns the {@link TemplateVariables} for sorting.
|
||||
*
|
||||
*
|
||||
* @param parameter can be {@literal null}.
|
||||
* @param components must not be {@literal null}.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -24,7 +24,7 @@ import org.springframework.util.StringUtils;
|
||||
|
||||
/**
|
||||
* {@link Projector} looking up a projection by name for the given source type.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class PersistentEntityProjector extends DefaultExcerptProjector implements Projector {
|
||||
@@ -36,7 +36,7 @@ public class PersistentEntityProjector extends DefaultExcerptProjector implement
|
||||
/**
|
||||
* Creates a new {@link PersistentEntityProjector} using the given {@link ProjectionDefinitions},
|
||||
* {@link ProjectionFactory} and projection name.
|
||||
*
|
||||
*
|
||||
* @param projectionDefinitions must not be {@literal null}.
|
||||
* @param factory must not be {@literal null}.
|
||||
* @param projection can be empty.
|
||||
@@ -69,7 +69,7 @@ public class PersistentEntityProjector extends DefaultExcerptProjector implement
|
||||
});
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.rest.webmvc.support.DefaultExcerptProjector#projectExcerpt(java.lang.Object)
|
||||
*/
|
||||
@@ -88,7 +88,7 @@ public class PersistentEntityProjector extends DefaultExcerptProjector implement
|
||||
/**
|
||||
* Creates the projection for the given source instance falling back to the given {@link Converter} if no explicit
|
||||
* projection is selected.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @param converter must not be {@literal null}.
|
||||
* @return
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -17,7 +17,7 @@ package org.springframework.data.rest.webmvc.support;
|
||||
|
||||
/**
|
||||
* Interface for a component being able to create projections for objects.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public interface Projector extends ExcerptProjector {
|
||||
@@ -25,7 +25,7 @@ public interface Projector extends ExcerptProjector {
|
||||
/**
|
||||
* Returns the projection object for the given source. This may result in the same object being returned or a
|
||||
* completely different acting as projection for the source.
|
||||
*
|
||||
*
|
||||
* @param source must not be {@literal null}.
|
||||
* @return
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2016 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -38,7 +38,7 @@ public class RepositoryConstraintViolationExceptionMessage {
|
||||
/**
|
||||
* Creates a new {@link RepositoryConstraintViolationExceptionMessage} for the given
|
||||
* {@link RepositoryConstraintViolationException} and {@link MessageSourceAccessor}.
|
||||
*
|
||||
*
|
||||
* @param exception must not be {@literal null}.
|
||||
* @param accessor must not be {@literal null}.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2015 the original author or authors.
|
||||
* Copyright 2012-2018 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.
|
||||
@@ -55,7 +55,7 @@ import org.springframework.web.util.UriComponentsBuilder;
|
||||
/**
|
||||
* {@link EntityLinks} implementation that is able to create {@link Link} for domain classes managed by Spring Data
|
||||
* REST.
|
||||
*
|
||||
*
|
||||
* @author Jon Brisbin
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
@@ -99,7 +99,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
|
||||
/**
|
||||
* Returns the link to to the paged colelction resource for the given type, pre-expanding the
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param pageable the pageable to can be {@literal null}.
|
||||
* @return
|
||||
@@ -146,7 +146,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
|
||||
/**
|
||||
* Returns all links to search resource for the given type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return
|
||||
* @since 2.3
|
||||
@@ -158,7 +158,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns all link to search resources for the given type, pre-expanded with the given {@link Pageable} if
|
||||
* applicable.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param pageable can be {@literal null}.
|
||||
* @return
|
||||
@@ -170,7 +170,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
|
||||
/**
|
||||
* Returns all link to search resources for the given type, pre-expanded with the given {@link Sort} if applicable.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param sort can be {@literal null}.
|
||||
* @return
|
||||
@@ -182,7 +182,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
|
||||
/**
|
||||
* Creates the link to the search resource with the given rel for a given type.
|
||||
*
|
||||
*
|
||||
* @param domainType must not be {@literal null}.
|
||||
* @param rel must not be {@literal null} or empty.
|
||||
* @return
|
||||
@@ -195,7 +195,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Creates the link to the search resource with the given rel for a given type. Uses the given {@link Pageable} to
|
||||
* pre-expand potentially available template variables.
|
||||
*
|
||||
*
|
||||
* @param domainType must not be {@literal null}.
|
||||
* @param rel must not be {@literal null} or empty.
|
||||
* @param pageable can be {@literal null}.
|
||||
@@ -209,7 +209,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Creates the link to the search resource with the given rel for a given type. Uses the given {@link Sort} to
|
||||
* pre-expand potentially available template variables.
|
||||
*
|
||||
*
|
||||
* @param domainType must not be {@literal null}.
|
||||
* @param rel must not be {@literal null} or empty.
|
||||
* @param sort can be {@literal null}.
|
||||
@@ -223,7 +223,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns all links to search resources of the given type. Pre-expands the template with the given {@link Pageable}
|
||||
* and {@link Sort} if applicable.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param pageable can be {@literal null}.
|
||||
* @param sort can be {@literal null}.
|
||||
@@ -245,7 +245,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns the link pointing to the search resource with the given rel of the given type and pre-expands the
|
||||
* calculated URi tempalte with the given {@link Pageable} and {@link Sort}.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @param rel must not be {@literal null} or empty.
|
||||
* @param pageable can be {@literal null}.
|
||||
@@ -280,7 +280,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns the {@link TemplateVariables} to be added for pagination for the given {@link UriComponentsBuilder} in case
|
||||
* the given {@link ResourceMapping} is a paging resource.
|
||||
*
|
||||
*
|
||||
* @param components must not be {@literal null}.
|
||||
* @param mapping must not be {@literal null}.
|
||||
* @param pageable can be {@literal null}.
|
||||
@@ -298,7 +298,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns all {@link TemplateVariables} that need to be added based on the given {@link UriComponents},
|
||||
* {@link MethodResourceMapping}, {@link Pageable} and {@link Sort}.
|
||||
*
|
||||
*
|
||||
* @param components must not be {@literal null}.
|
||||
* @param mapping must not be {@literal null}.
|
||||
* @param pageable can be {@literal null}
|
||||
@@ -318,7 +318,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
/**
|
||||
* Returns the {@link TemplateVariables} for the projection parameter if projections are vonfigured for the given
|
||||
* type.
|
||||
*
|
||||
*
|
||||
* @param type must not be {@literal null}.
|
||||
* @return will never be {@literal null}.
|
||||
*/
|
||||
@@ -335,7 +335,7 @@ public class RepositoryEntityLinks extends AbstractEntityLinks {
|
||||
|
||||
/**
|
||||
* Returns the {@link TemplateVariables} for all parameters of the given {@link MethodResourceMapping}.
|
||||
*
|
||||
*
|
||||
* @param mapping must not be {@literal null}.
|
||||
* @return will never be {@literal null}.
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2013-2014 the original author or authors.
|
||||
* Copyright 2013-2018 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.
|
||||
@@ -28,7 +28,7 @@ import org.springframework.web.util.UriComponentsBuilder;
|
||||
|
||||
/**
|
||||
* {@link LinkBuilder} to be able to create links pointing to repositories.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
*/
|
||||
public class RepositoryLinkBuilder extends LinkBuilderSupport<RepositoryLinkBuilder> {
|
||||
@@ -37,7 +37,7 @@ public class RepositoryLinkBuilder extends LinkBuilderSupport<RepositoryLinkBuil
|
||||
|
||||
/**
|
||||
* Creates a new {@link RepositoryLinkBuilder} with the given {@link ResourceMetadata} and base {@link URI}.
|
||||
*
|
||||
*
|
||||
* @param metadata must not be {@literal null}.
|
||||
* @param baseUri
|
||||
*/
|
||||
@@ -48,7 +48,7 @@ public class RepositoryLinkBuilder extends LinkBuilderSupport<RepositoryLinkBuil
|
||||
/**
|
||||
* Creates a new {@link RepositoryLinkBuilder} with the given {@link ResourceMetadata} and
|
||||
* {@link UriComponentsBuilder}.
|
||||
*
|
||||
*
|
||||
* @param metadata must not be {@literal null}.
|
||||
* @param builder must not be {@literal null}.
|
||||
*/
|
||||
@@ -81,7 +81,7 @@ public class RepositoryLinkBuilder extends LinkBuilderSupport<RepositoryLinkBuil
|
||||
return withRel(metadata.getRel());
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.core.LinkBuilderSupport#createNewInstance(org.springframework.web.util.UriComponentsBuilder)
|
||||
*/
|
||||
@@ -90,7 +90,7 @@ public class RepositoryLinkBuilder extends LinkBuilderSupport<RepositoryLinkBuil
|
||||
return new RepositoryLinkBuilder(this.metadata, builder);
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.hateoas.core.LinkBuilderSupport#getThis()
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2016 the original author or authors.
|
||||
* Copyright 2014-2018 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.
|
||||
@@ -26,7 +26,7 @@ import org.springframework.web.util.UriComponentsBuilder;
|
||||
|
||||
/**
|
||||
* Utility methods to work with requests and URIs.
|
||||
*
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Mark Paluch
|
||||
*/
|
||||
@@ -38,7 +38,7 @@ public abstract class UriUtils {
|
||||
|
||||
/**
|
||||
* Returns the value for the mapping variable with the given name.
|
||||
*
|
||||
*
|
||||
* @param variable must not be {@literal null} or empty.
|
||||
* @param method must not be {@literal null}.
|
||||
* @param lookupPath
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user