public class TypedResourceDescription extends SimpleResourceDescription
SimpleResourceDescription that additionally captures a type to be able to potentially create a reasonable
default message. The implementation will do so for enum types by rendering the available values as default message
and also provide them as arguments for message resolution.DEFAULT_KEY_PREFIX, DEFAULT_MEDIA_TYPE| Modifier and Type | Method and Description |
|---|---|
static ResourceDescription |
defaultFor(org.springframework.hateoas.LinkRelation rel,
Class<?> type) |
static ResourceDescription |
defaultFor(org.springframework.hateoas.LinkRelation rel,
PersistentProperty<?> property) |
static ResourceDescription |
defaultFor(org.springframework.hateoas.LinkRelation rel,
String name,
Class<?> type) |
Object[] |
getArguments() |
String |
getDefaultMessage() |
defaultFor, getCodes, getMessage, getType, isDefaultpublic static ResourceDescription defaultFor(org.springframework.hateoas.LinkRelation rel, PersistentProperty<?> property)
public static ResourceDescription defaultFor(org.springframework.hateoas.LinkRelation rel, String name, Class<?> type)
public static ResourceDescription defaultFor(org.springframework.hateoas.LinkRelation rel, Class<?> type)
public Object[] getArguments()
getArguments in interface MessageSourceResolvablegetArguments in class ResolvableResourceDescriptionSupportpublic String getDefaultMessage()
getDefaultMessage in interface MessageSourceResolvablegetDefaultMessage in class ResolvableResourceDescriptionSupportCopyright © 2011–2021 Pivotal Software, Inc.. All rights reserved.