Class ItemLinksBuilder
java.lang.Object
org.eclipse.persistence.jpa.rs.features.ItemLinksBuilder
Convenient
ItemLinks
object builder.- Since:
- EclipseLink 2.6.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddAlternate
(String href) Adds a 'alternate' link.addCanonical
(String href) Adds a 'canonical' link.addCanonical
(String href, String mediaType) Adds a 'canonical' link.Adds a 'create' link.Adds a 'delete' link.addDescribedBy
(String href) Adds a 'describedBy' link.addDescribes
(String href) Adds a 'describes' link.addExecute
(String href, String method) Adds a 'execute' link.Adds a 'find' link.Adds a 'next' link.Adds a 'prev' link.Adds a 'self' link.Adds a 'update' link.build()
BuildsItemLinks
object.getList()
Returns a list of links.
-
Constructor Details
-
ItemLinksBuilder
public ItemLinksBuilder()
-
-
Method Details
-
addSelf
Adds a 'self' link.- Parameters:
href
- 'self' link- Returns:
ItemLinksBuilder
with added 'self' link.
-
addCanonical
Adds a 'canonical' link.- Parameters:
href
- 'canonical' link- Returns:
ItemLinksBuilder
with added 'canonical' link.
-
addCanonical
Adds a 'canonical' link.- Parameters:
href
- 'canonical' linkmediaType
- media type- Returns:
ItemLinksBuilder
with added 'canonical' link.
-
addNext
Adds a 'next' link.- Parameters:
href
- 'next' link- Returns:
ItemLinksBuilder
with added 'next' link.
-
addPrev
Adds a 'prev' link.- Parameters:
href
- 'prev' link- Returns:
ItemLinksBuilder
with added 'prev' link.
-
addAlternate
Adds a 'alternate' link. Alternate links always have "application/schema+json" media type.- Parameters:
href
- 'alternate' link- Returns:
ItemLinksBuilder
with added 'alternate' link.
-
addDescribes
Adds a 'describes' link.- Parameters:
href
- 'describes' link- Returns:
ItemLinksBuilder
with added 'describes' link.
-
addDescribedBy
Adds a 'describedBy' link.- Parameters:
href
- 'describedBy' link- Returns:
ItemLinksBuilder
with added 'describedBy' link.
-
addCreate
Adds a 'create' link.- Parameters:
href
- 'create' link- Returns:
ItemLinksBuilder
with added 'create' link.
-
addFind
Adds a 'find' link.- Parameters:
href
- 'find' link- Returns:
ItemLinksBuilder
with added 'find' link.
-
addUpdate
Adds a 'update' link.- Parameters:
href
- 'update' link- Returns:
ItemLinksBuilder
with added 'update' link.
-
addDelete
Adds a 'delete' link.- Parameters:
href
- 'delete' link- Returns:
ItemLinksBuilder
with added 'delete' link.
-
addExecute
Adds a 'execute' link.- Parameters:
href
- 'execute' linkmethod
- GET/POST etc.- Returns:
ItemLinksBuilder
with added 'execute' link.
-
build
BuildsItemLinks
object.- Returns:
ItemLinks
object.
-
getList
Returns a list of links.- Returns:
- list of links.
-