@ProviderType public final class Link extends Object
LinkHandler.| Constructor and Description |
|---|
Link(LinkType linkType,
LinkRequest linkRequest) |
| Modifier and Type | Method and Description |
|---|---|
io.wcm.handler.commons.dom.Anchor |
getAnchor() |
Map<String,String> |
getAnchorAttributes() |
LinkRequest |
getLinkRequest() |
LinkType |
getLinkType() |
String |
getMarkup() |
io.wcm.handler.media.Asset |
getTargetAsset() |
com.day.cq.wcm.api.Page |
getTargetPage() |
io.wcm.handler.media.Rendition |
getTargetRendition() |
String |
getUrl() |
boolean |
isLinkReferenceInvalid() |
boolean |
isValid() |
void |
setAnchor(io.wcm.handler.commons.dom.Anchor anchor) |
void |
setLinkReferenceInvalid(boolean linkReferenceInvalid) |
void |
setLinkRequest(LinkRequest linkRequest) |
void |
setTargetAsset(io.wcm.handler.media.Asset targetAsset) |
void |
setTargetPage(com.day.cq.wcm.api.Page targetPage) |
void |
setTargetRendition(io.wcm.handler.media.Rendition targetRendition) |
void |
setUrl(String url) |
String |
toString() |
public Link(LinkType linkType, LinkRequest linkRequest)
linkType - Link typelinkRequest - Processed link referencepublic LinkType getLinkType()
public LinkRequest getLinkRequest()
public void setLinkRequest(LinkRequest linkRequest)
linkRequest - Link requestpublic boolean isLinkReferenceInvalid()
public void setLinkReferenceInvalid(boolean linkReferenceInvalid)
linkReferenceInvalid - true if a link reference was set, but the reference was invalid and could not be
resolvedpublic io.wcm.handler.commons.dom.Anchor getAnchor()
public Map<String,String> getAnchorAttributes()
public void setAnchor(io.wcm.handler.commons.dom.Anchor anchor)
anchor - Anchor elementpublic String getMarkup()
public String getUrl()
public void setUrl(String url)
url - Link URLpublic com.day.cq.wcm.api.Page getTargetPage()
public void setTargetPage(com.day.cq.wcm.api.Page targetPage)
targetPage - Target page referenced by the link (applies only for internal links)public io.wcm.handler.media.Asset getTargetAsset()
public void setTargetAsset(io.wcm.handler.media.Asset targetAsset)
targetAsset - Target media item (applies only for media links)public io.wcm.handler.media.Rendition getTargetRendition()
public void setTargetRendition(io.wcm.handler.media.Rendition targetRendition)
targetRendition - Target media rendition (applies only for media links)public boolean isValid()
Copyright © 2014–2017 wcm.io. All rights reserved.