Class Link
java.lang.Object
org.springframework.restdocs.hypermedia.Link
Representation of a link used in a Hypermedia-based API.
- Author:
- Andy Wilkinson
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
Link
Creates a newLink
with the givenrel
andhref
.- Parameters:
rel
- the link's relhref
- the link's href
-
Link
Creates a newLink
with the givenrel
,href
, andtitle
.- Parameters:
rel
- the link's relhref
- the link's hreftitle
- the link's title
-
-
Method Details
-
getRel
Returns the link'srel
.- Returns:
- the link's
rel
-
getHref
Returns the link'shref
.- Returns:
- the link's
href
-
getTitle
Returns the link'stitle
, ornull
if it does not have a title.- Returns:
- the link's
title
ornull
-
equals
-
hashCode
public int hashCode() -
toString
-