@Bean(typeName="link") public class Link extends Common
atomLink = element atom:link { atomCommonAttributes, attribute href { atomUri }, attribute rel { atomNCName | atomUri }?, attribute type { atomMediaType }?, attribute hreflang { atomLanguageTag }?, attribute title { text }?, attribute length { text }?, undefinedContent }
Constructor and Description |
---|
Link()
Bean constructor.
|
Link(String rel,
String type,
String href)
Normal constructor.
|
Modifier and Type | Method and Description |
---|---|
Link |
base(Object base)
Sets the URI base of this object.
|
String |
getHref()
Returns the href of the target of this link.
|
String |
getHreflang()
Returns the language of the target of this link.
|
Integer |
getLength()
Returns the length of the contents of the target of this link.
|
String |
getRel()
Returns the rel of this link.
|
String |
getTitle()
Returns the title of the target of this link.
|
String |
getType()
Returns the content type of the target of this link.
|
Link |
href(String href)
Sets the href of the target of this link.
|
Link |
hreflang(String hreflang)
Sets the language of the target of this link.
|
Link |
lang(String lang)
Sets the language of this object.
|
Link |
length(Integer length)
Sets the length of the contents of the target of this link.
|
Link |
rel(String rel)
Sets the rel of this link.
|
Link |
title(String title)
Sets the title of the target of this link.
|
Link |
type(String type)
Sets the content type of the target of this link.
|
public Link(String rel, String type, String href)
rel
- The rel of the link.type
- The type of the link.href
- The URI of the link.public Link()
@Xml(format=ATTR) public String getHref()
@BeanProperty(value="href") public Link href(String href)
href
- The href of the target of this link.@Xml(format=ATTR) public String getRel()
@BeanProperty(value="rel") public Link rel(String rel)
rel
- The rel of this link.@Xml(format=ATTR) public String getType()
@BeanProperty(value="type") public Link type(String type)
Must be one of the following:
type
- The content type of the target of this link.@Xml(format=ATTR) public String getHreflang()
@BeanProperty(value="hreflang") public Link hreflang(String hreflang)
hreflang
- The language of the target of this link.@Xml(format=ATTR) public String getTitle()
@BeanProperty(value="title") public Link title(String title)
title
- The title of the target of this link.@Xml(format=ATTR) public Integer getLength()
@BeanProperty(value="length") public Link length(Integer length)
length
- The length of the contents of the target of this link.public Link base(Object base)
Common
The value can be of any of the following types: URI
, URL
, String
.
Strings must be valid URIs.
URIs defined by UriResolver
can be used for values.
Copyright © 2016–2019 The Apache Software Foundation. All rights reserved.