Interface ResourceLinkResolver
-
- All Known Implementing Classes:
AbstractResourceLinkResolver
public interface ResourceLinkResolver
Responsible for resolving a link (type ofResourceLink
) for aResource
representation.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ResourceLink
resolve(Resource resource)
Resolves aResourceLink
for the givenresource
.ResourceLink
resolve(Resource resource, Map<String,Object> linkVariables)
Resolves aResourceLink
for the givenresource
with passinglinkVariables
that can be used by implementation to expand its internal link generation template.
-
-
-
Method Detail
-
resolve
ResourceLink resolve(Resource resource) throws ResourceException
Resolves aResourceLink
for the givenresource
.- Parameters:
resource
- resource representation- Returns:
- a
ResourceLink
for the givenresource
- Throws:
ResourceException
- if resource resolution operation fails
-
resolve
ResourceLink resolve(Resource resource, Map<String,Object> linkVariables) throws ResourceException
Resolves aResourceLink
for the givenresource
with passinglinkVariables
that can be used by implementation to expand its internal link generation template.How the
linkVariables
is used in link generation template expansion is totally up to an implementation.- Parameters:
resource
- resource representationlinkVariables
- the variables to expand the internal link generation template- Returns:
- a
ResourceLink
for the givenresource
- Throws:
ResourceException
- if resource resolution operation fails
-
-