Class ProfileController
java.lang.Object
org.springframework.data.rest.webmvc.ProfileController
Profile-based controller exposing multiple forms of metadata.
- Since:
- 2.4
- Author:
- Greg Turnquist, Oliver Gierke
-
Field Summary
-
Constructor Summary
ConstructorDescriptionProfileController
(RepositoryRestConfiguration configuration, RepositoryResourceMappings mappings, org.springframework.data.repository.support.Repositories repositories) Wire up the controller with a copy ofRepositoryRestConfiguration
. -
Method Summary
Modifier and TypeMethodDescriptionstatic String
getPath
(RepositoryRestConfiguration configuration, ResourceMapping mapping) Return the href for the profile link of a given baseUri and domain type mapping.static String
getRootPath
(RepositoryRestConfiguration configuration) Return the href for the profile root link of a given baseUri.org.springframework.http.HttpEntity<?>
List the OPTIONS for this controller.
-
Field Details
-
PROFILE_ROOT_MAPPING
- See Also:
-
RESOURCE_PROFILE_MAPPING
- See Also:
-
-
Constructor Details
-
ProfileController
@Autowired public ProfileController(RepositoryRestConfiguration configuration, RepositoryResourceMappings mappings, org.springframework.data.repository.support.Repositories repositories) Wire up the controller with a copy ofRepositoryRestConfiguration
.- Parameters:
configuration
- must not be null.mappings
- must not be null.repositories
- must not be null.
-
-
Method Details
-
profileOptions
@RequestMapping(value="/profile", method=OPTIONS) public org.springframework.http.HttpEntity<?> profileOptions()List the OPTIONS for this controller.- Returns:
-
getRootPath
Return the href for the profile root link of a given baseUri.- Parameters:
configuration
- is the source of the app's baseUri.- Returns:
-
getPath
Return the href for the profile link of a given baseUri and domain type mapping.- Parameters:
configuration
- is the source of the app's baseUri.mapping
- provides the resource's path.- Returns:
-