public interface Link
Modifier and Type | Interface and Description |
---|---|
static class |
Link.LinkType
Type of a link.
|
Modifier and Type | Method and Description |
---|---|
String |
getAlternative()
Get the link alternative.
|
String |
getContent()
Get the link content.
|
String |
getDynamicInformationProvider()
Get the id of the provider of dynamic information.
|
BinaryMetadata |
getExternalPicture()
Get the picture as a binary metadata.
|
GroupIdentity[] |
getGrantedGroups()
Get the list of granted groups
|
UserIdentity[] |
getGrantedUsers()
Get the list of granted users
|
String |
getInternalUrl()
Get the internal URL.
|
String |
getPictureAlternative()
Get the picture alternative.
|
String |
getPictureType()
Get the picture type.
|
String |
getResourcePictureId()
Get the picture resource ID.
|
String[] |
getThemes()
Get the themes.
|
String |
getTitle()
Get the link title.
|
String |
getUrl()
Get the URL.
|
Link.LinkType |
getUrlType()
Retrieves the linked URL type.
|
boolean |
isAllowedAnyUser()
Is any connected user allowed ?
|
void |
removeTheme(String themeId)
Remove theme if exist
|
void |
setAlternative(String alternative)
Set the link alternative.
|
void |
setContent(String content)
Set the content.
|
void |
setDynamicInformationProvider(String providerId)
Set the id of the provider of dynamic information.
|
void |
setExternalPicture(String mimeType,
String filename,
InputStream stream)
Set the picture from an external file.
|
void |
setGrantAnyUser(boolean allowAnyUser)
Determines if any connected user will be granted access to this link,
depending on the parameter's value
|
void |
setGrantedGroups(GroupIdentity[] grantedGroups)
Set the list of granted groups
|
void |
setGrantedUsers(UserIdentity[] grantedUsers)
Set the list of granted users
|
void |
setInternalUrl(String url)
Set the internal URL.
|
void |
setNoPicture()
Removes any picture currently assigned.
|
void |
setPictureAlternative(String alternative)
Set the picture alternative.
|
void |
setPictureType(String type)
Set the picture type.
|
void |
setResourcePicture(String resourceId)
Set the picture from an explorer resource.
|
void |
setThemes(String[] themes)
Set the themes.
|
void |
setTitle(String title)
Set the title.
|
void |
setUrl(Link.LinkType type,
String url)
Set the URL.
|
String getUrl() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setUrl(Link.LinkType type, String url) throws AmetysRepositoryException
type
- The URL typeurl
- the link URL to set.AmetysRepositoryException
- if an error occurs.String getInternalUrl() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setInternalUrl(String url) throws AmetysRepositoryException
url
- the link internal URL to set.AmetysRepositoryException
- if an error occurs.Link.LinkType getUrlType() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.String getTitle() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setTitle(String title) throws AmetysRepositoryException
title
- the link title to set.AmetysRepositoryException
- if an error occurs.String getContent() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setContent(String content) throws AmetysRepositoryException
content
- the link content to set.AmetysRepositoryException
- if an error occurs.String getAlternative() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setAlternative(String alternative) throws AmetysRepositoryException
alternative
- the link alternative to set.AmetysRepositoryException
- if an error occurs.BinaryMetadata getExternalPicture() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setExternalPicture(String mimeType, String filename, InputStream stream) throws AmetysRepositoryException
mimeType
- the file MIME type.filename
- the file name.stream
- an input stream on the file bytes.AmetysRepositoryException
- if an error occurs.String getResourcePictureId() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setResourcePicture(String resourceId) throws AmetysRepositoryException
resourceId
- the resource ID.AmetysRepositoryException
- if an error occurs.void setNoPicture() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.String getPictureType() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setPictureType(String type) throws AmetysRepositoryException
type
- the picture type to set.AmetysRepositoryException
- if an error occurs.String getPictureAlternative() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setPictureAlternative(String alternative) throws AmetysRepositoryException
alternative
- the picture alternative to set.AmetysRepositoryException
- if an error occurs.String[] getThemes() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setThemes(String[] themes) throws AmetysRepositoryException
themes
- the themes to set.AmetysRepositoryException
- if an error occurs.void removeTheme(String themeId) throws AmetysRepositoryException
themeId
- The id of theme to removeAmetysRepositoryException
- if an error occursUserIdentity[] getGrantedUsers() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occursvoid setGrantedUsers(UserIdentity[] grantedUsers) throws AmetysRepositoryException
grantedUsers
- the users who will have access to this linkAmetysRepositoryException
- if an error occursGroupIdentity[] getGrantedGroups() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occursvoid setGrantedGroups(GroupIdentity[] grantedGroups) throws AmetysRepositoryException
grantedGroups
- the groups who will have access to this linkAmetysRepositoryException
- if an exception occursboolean isAllowedAnyUser() throws AmetysRepositoryException
AmetysRepositoryException
- if an exceptions occursvoid setGrantAnyUser(boolean allowAnyUser) throws AmetysRepositoryException
allowAnyUser
- "true" to allow any connected user, "false" otherwiseAmetysRepositoryException
- if a an exception occurs while
exploring the repositoryString getDynamicInformationProvider() throws AmetysRepositoryException
AmetysRepositoryException
- if an error occurs.void setDynamicInformationProvider(String providerId) throws AmetysRepositoryException
providerId
- the id of providerAmetysRepositoryException
- if an error occurs.