de.smartics.resteasy.hypermedia.renderer
Class LinkDescriptorAtom

Package class diagram package LinkDescriptorAtom
java.lang.Object
  extended by javax.ws.rs.core.Link
      extended by de.smartics.resteasy.hypermedia.renderer.LinkDescriptor
          extended by de.smartics.resteasy.hypermedia.renderer.LinkDescriptorAtom

public final class LinkDescriptorAtom
     
     
extends LinkDescriptor

Provides information on a single link.


Nested Class Summary
 
Nested classes/interfaces inherited from class javax.ws.rs.core.Link
javax.ws.rs.core.Link.Builder, javax.ws.rs.core.Link.JaxbAdapter, javax.ws.rs.core.Link.JaxbLink
 
Field Summary
 
Fields inherited from class de.smartics.resteasy.hypermedia.renderer.LinkDescriptor
metadata, params, rels
 
Fields inherited from class javax.ws.rs.core.Link
REL, TITLE, TYPE
 
Constructor Summary
LinkDescriptorAtom(org.jboss.resteasy.links.RESTServiceDiscovery.AtomLink atomLink)
          Convenience constructor with empty metadata.
LinkDescriptorAtom(org.jboss.resteasy.links.RESTServiceDiscovery.AtomLink atomLink, LinkMetadata metadata)
          Default constructor.
 
Method Summary
 String getHref()
          Returns the URI to the resource the link points to.
 String getHrefLang()
          Returns the content that describes the language of the resource pointed to by the link.
 String getLength()
          Returns the advisory length of the linked content in octets; it is a hint about the content length of the representation returned when the IRI in the href attribute is mapped to a URI and dereferenced.
 String getTitle()
          Returns the advisory information associated with the element.
 String getType()
          Returns the media type of the resource the link points to.
 void setHref(String href)
          Sets the URI to the resource the link points to.
 void setHrefLang(String hreflang)
          Sets the content that describes the language of the resource pointed to by the link.
 void setLength(String length)
          Sets the advisory length of the linked content in octets; it is a hint about the content length of the representation returned when the IRI in the href attribute is mapped to a URI and dereferenced.
 void setType(String type)
          Sets the media type of the resource the link points to.
 
Methods inherited from class de.smartics.resteasy.hypermedia.renderer.LinkDescriptor
addRels, addRels, getAccessKey, getContextMenu, getCssClass, getDir, getHelp, getId, getLabel, getMedia, getParams, getRel, getRels, getShortLabel, getTabIndex, getTarget, getUri, getUriBuilder, isHidden, putParam, setAccessKey, setContextMenu, setCssClass, setDir, setHelp, setHidden, setId, setLabel, setMedia, setShortLabel, setTabIndex, setTarget, setTitle, splitRel, toString
 
Methods inherited from class javax.ws.rs.core.Link
fromLink, fromMethod, fromPath, fromResource, fromUri, fromUri, fromUriBuilder, valueOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LinkDescriptorAtom

public LinkDescriptorAtom(org.jboss.resteasy.links.RESTServiceDiscovery.AtomLink atomLink)
Convenience constructor with empty metadata.

Parameters:
atomLink - the basic link information provided by RESTEasy.

LinkDescriptorAtom

public LinkDescriptorAtom(org.jboss.resteasy.links.RESTServiceDiscovery.AtomLink atomLink,
                          LinkMetadata metadata)
Default constructor.

Parameters:
atomLink - the basic link information provided by RESTEasy.
metadata - the additional link metadata about the link.
Method Detail

getHref

public String getHref()
Description copied from class: LinkDescriptor
Returns the URI to the resource the link points to.

Specified by:
getHref in class LinkDescriptor
Returns:
the URI to the resource the link points to.

setHref

public void setHref(String href)
Description copied from class: LinkDescriptor
Sets the URI to the resource the link points to.

Specified by:
setHref in class LinkDescriptor
Parameters:
href - the URI to the resource the link points to.

getType

public String getType()
Description copied from class: LinkDescriptor
Returns the media type of the resource the link points to.

Specified by:
getType in class LinkDescriptor
Returns:
the media type of the resource the link points to.

setType

public void setType(String type)
Description copied from class: LinkDescriptor
Sets the media type of the resource the link points to.

Specified by:
setType in class LinkDescriptor
Parameters:
type - the media type of the resource the link points to.

getHrefLang

public String getHrefLang()
Description copied from class: LinkDescriptor
Returns the content that describes the language of the resource pointed to by the link. When used together with the rel="alternate", it implies a translated version of the entry. Link elements MAY have an hreflang attribute, whose value MUST be a language tag [RFC3066].

Specified by:
getHrefLang in class LinkDescriptor
Returns:
the content that describes the language of the resource pointed to by the link.

setHrefLang

public void setHrefLang(String hreflang)
Description copied from class: LinkDescriptor
Sets the content that describes the language of the resource pointed to by the link. When used together with the rel="alternate", it implies a translated version of the entry. Link elements MAY have an hreflang attribute, whose value MUST be a language tag [RFC3066].

Specified by:
setHrefLang in class LinkDescriptor
Parameters:
hreflang - the content that describes the language of the resource pointed to by the link.

getLength

public String getLength()
Description copied from class: LinkDescriptor
Returns the advisory length of the linked content in octets; it is a hint about the content length of the representation returned when the IRI in the href attribute is mapped to a URI and dereferenced. Note that the length attribute does not override the actual content length of the representation as reported by the underlying protocol. Link elements MAY have a length attribute.

Specified by:
getLength in class LinkDescriptor
Returns:
the advisory length of the linked content in octets.

setLength

public void setLength(String length)
Description copied from class: LinkDescriptor
Sets the advisory length of the linked content in octets; it is a hint about the content length of the representation returned when the IRI in the href attribute is mapped to a URI and dereferenced. Note that the length attribute does not override the actual content length of the representation as reported by the underlying protocol. Link elements MAY have a length attribute.

Specified by:
setLength in class LinkDescriptor
Parameters:
length - the advisory length of the linked content in octets.

getTitle

public String getTitle()
Description copied from class: LinkDescriptor
Returns the advisory information associated with the element.

Overrides:
getTitle in class LinkDescriptor
Returns:
the advisory information associated with the element.


Copyright © 2013 Kronseder & Reiner GmbH - smartics. All Rights Reserved.