Package org.ametys.plugins.linkdirectory
Interface Link
- All Known Implementing Classes:
 DefaultLink
public interface Link
A link in the directory.
- 
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumStatus of a link.static enumType of a link. - 
Method Summary
Modifier and TypeMethodDescriptionGet the link alternative.getColor()Get the color.Get the link content.Get the id of the provider of dynamic information.Get the picture as a binary metadata.Get the internal URL.getPage()Get the page.Get the picture alternative.Get the picture glyph.Get the picture type.Get the picture resource ID.Get the status.String[]Get the themes.getTitle()Get the link title.getUrl()Get the URL.Retrieves the linked URL type.voidremoveTheme(String themeId) Remove theme if existvoidsetAlternative(String alternative) Set the link alternative.voidSet the color.voidsetContent(String content) Set the content.voidsetDynamicInformationProvider(String providerId) Set the id of the provider of dynamic information.voidsetExternalPicture(String mimeType, String filename, InputStream stream) Set the picture from an external file.voidsetInternalUrl(String url) Set the internal URL.voidRemoves any picture currently assigned.voidSet the page.voidsetPictureAlternative(String alternative) Set the picture alternative.voidsetPictureGlyph(String glyph) Set the picture glyph.voidsetPictureType(String type) Set the picture type.voidsetResourcePicture(String resourceId) Set the picture from an explorer resource.voidsetStatus(Link.LinkStatus status) Set the status.voidSet the themes.voidSet the title.voidsetUrl(Link.LinkType type, String url) Set the URL. 
- 
Method Details
- 
getUrl
Get the URL.- Returns:
 - the link URL.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setUrl
Set the URL.- Parameters:
 type- The URL typeurl- the link URL to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getInternalUrl
Get the internal URL.- Returns:
 - the link internal URL.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setInternalUrl
Set the internal URL.- Parameters:
 url- the link internal URL to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getUrlType
Retrieves the linked URL type.- Returns:
 - the linked URL type.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getTitle
Get the link title.- Returns:
 - the link title.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setTitle
Set the title.- Parameters:
 title- the link title to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getContent
Get the link content.- Returns:
 - the link content.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setContent
Set the content.- Parameters:
 content- the link content to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getAlternative
Get the link alternative.- Returns:
 - the link alternative.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setAlternative
Set the link alternative.- Parameters:
 alternative- the link alternative to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getExternalPicture
Get the picture as a binary metadata.- Returns:
 - the picture as a binary metadata.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setExternalPicture
void setExternalPicture(String mimeType, String filename, InputStream stream) throws AmetysRepositoryException Set the picture from an external file.- Parameters:
 mimeType- the file MIME type.filename- the file name.stream- an input stream on the file bytes.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getResourcePictureId
Get the picture resource ID.- Returns:
 - the resource ID.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setResourcePicture
Set the picture from an explorer resource.- Parameters:
 resourceId- the resource ID.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setNoPicture
Removes any picture currently assigned.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getPictureType
Get the picture type.- Returns:
 - the picture type.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setPictureType
Set the picture type.- Parameters:
 type- the picture type to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getPictureGlyph
Get the picture glyph.- Returns:
 - the picture glyph.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setPictureGlyph
Set the picture glyph.- Parameters:
 glyph- the glyph picture to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getPictureAlternative
Get the picture alternative.- Returns:
 - the picture alternative.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setPictureAlternative
Set the picture alternative.- Parameters:
 alternative- the picture alternative to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getThemes
Get the themes.- Returns:
 - the themes in an Array
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setThemes
Set the themes.- Parameters:
 themes- the themes to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
removeTheme
Remove theme if exist- Parameters:
 themeId- The id of theme to remove- Throws:
 AmetysRepositoryException- if an error occurs
 - 
getDynamicInformationProvider
Get the id of the provider of dynamic information.- Returns:
 - the id of provider. Can be null.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setDynamicInformationProvider
Set the id of the provider of dynamic information.- Parameters:
 providerId- the id of provider- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getColor
Get the color.- Returns:
 - the color.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setColor
Set the color.- Parameters:
 color- the color to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getPage
Get the page.- Returns:
 - the page.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setPage
Set the page.- Parameters:
 pageId- the page id to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 - 
getStatus
Get the status.- Returns:
 - the status.
 - Throws:
 AmetysRepositoryException- if an error occurs.
 - 
setStatus
Set the status.- Parameters:
 status- the status to set.- Throws:
 AmetysRepositoryException- if an error occurs.
 
 -