public class Link extends Object
Constructor and Description |
---|
Link() |
Link(String href,
String rel,
String type,
String title)
Initializes a new instance of the Link
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
String |
getHref()
The \"href\" attribute contains the link's IRI.
|
String |
getRel()
atom:link elements MAY have a \"rel\" attribute that indicates the link relation type.
|
String |
getTitle()
The \"title\" attribute conveys human-readable information about the link.
|
String |
getType()
On the link element, the \"type\" attribute's value is an advisory media type: it is a hint about the type of the representation that is expected to be returned when the value of the href attribute is dereferenced.
|
int |
hashCode() |
Link |
href(String href)
Set href and return this.
|
Link |
rel(String rel)
Set rel and return this.
|
void |
setHref(String href)
Set href.
|
void |
setRel(String rel)
Set rel.
|
void |
setTitle(String title)
Set title.
|
void |
setType(String type)
Set type.
|
Link |
title(String title)
Set title and return this.
|
String |
toString() |
Link |
type(String type)
Set type and return this.
|
public Link()
public Link(String href, String rel, String type, String title)
href
- The \"href\" attribute contains the link's IRI. atom:link elements MUST have an href attribute, whose value MUST be a IRI referencerel
- atom:link elements MAY have a \"rel\" attribute that indicates the link relation type. If the \"rel\" attribute is not present, the link element MUST be interpreted as if the link relation type is \"alternate\".type
- On the link element, the \"type\" attribute's value is an advisory media type: it is a hint about the type of the representation that is expected to be returned when the value of the href attribute is dereferenced. Note that the type attribute does not override the actual media type returned with the representation.title
- The \"title\" attribute conveys human-readable information about the link. The content of the \"title\" attribute is Language-Sensitive.public Link href(String href)
href
- The \"href\" attribute contains the link's IRI. atom:link elements MUST have an href attribute, whose value MUST be a IRI referencepublic String getHref()
public void setHref(String href)
href
- The \"href\" attribute contains the link's IRI. atom:link elements MUST have an href attribute, whose value MUST be a IRI referencepublic Link rel(String rel)
rel
- atom:link elements MAY have a \"rel\" attribute that indicates the link relation type. If the \"rel\" attribute is not present, the link element MUST be interpreted as if the link relation type is \"alternate\".public String getRel()
public void setRel(String rel)
rel
- atom:link elements MAY have a \"rel\" attribute that indicates the link relation type. If the \"rel\" attribute is not present, the link element MUST be interpreted as if the link relation type is \"alternate\".public Link type(String type)
type
- On the link element, the \"type\" attribute's value is an advisory media type: it is a hint about the type of the representation that is expected to be returned when the value of the href attribute is dereferenced. Note that the type attribute does not override the actual media type returned with the representation.public String getType()
public void setType(String type)
type
- On the link element, the \"type\" attribute's value is an advisory media type: it is a hint about the type of the representation that is expected to be returned when the value of the href attribute is dereferenced. Note that the type attribute does not override the actual media type returned with the representation.public Link title(String title)
title
- The \"title\" attribute conveys human-readable information about the link. The content of the \"title\" attribute is Language-Sensitive.public String getTitle()
public void setTitle(String title)
title
- The \"title\" attribute conveys human-readable information about the link. The content of the \"title\" attribute is Language-Sensitive.Copyright © 2020. All rights reserved.