public static class Link.Builder
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
Link |
build()
Builds the Link instance.
|
Link.Builder |
withDeprecation(java.lang.String deprecation)
Set deprecation attribute.
|
Link.Builder |
withHref(java.lang.String href)
Set the href of the linked resource
If href is an URI template, the created link
is templated and Link.templated
will be true. |
Link.Builder |
withHrefLang(java.lang.String hrefLang)
Set the language of the linked resource
|
Link.Builder |
withName(java.lang.String name)
Set the name attribute.
|
Link.Builder |
withProfile(java.lang.String profile)
Set the profile attribute
|
Link.Builder |
withRel(java.lang.String rel)
Set the rel of the linked resource
|
Link.Builder |
withTitle(java.lang.String title)
Set the title attribute
|
Link.Builder |
withType(java.lang.String type)
Set the media type of the linked resource
|
public Link.Builder withRel(java.lang.String rel)
rel
- link-relation typepublic Link.Builder withHref(java.lang.String href)
If href is an URI template, the created link is templated
and Link.templated
will be true.
href
- hrefpublic Link.Builder withType(java.lang.String type)
type
- media typepublic Link.Builder withHrefLang(java.lang.String hrefLang)
hrefLang
- the hreflang of the Linkpublic Link.Builder withTitle(java.lang.String title)
title
- the title of the linked resource.public Link.Builder withName(java.lang.String name)
name
- the name of the linked resource.public Link.Builder withProfile(java.lang.String profile)
profile
- the profile of the representationpublic Link.Builder withDeprecation(java.lang.String deprecation)
Set deprecation attribute.
Its presence indicates that the link is to be deprecated (i.e. removed) at a future date. Its value is a URL that SHOULD provide further information about the deprecation.
deprecation
- URL pointing to further informationpublic Link build()