public class Project extends DefaultTraversableAmetysObject<ProjectFactory> implements ProjectsTreeNode, ModifiableModelLessDataAwareAmetysObject, EventHolder
AmetysObject for storing project informations.| Modifier and Type | Class and Description |
|---|---|
static class |
Project.InscriptionStatus
The inscription status of the project
|
| Modifier and Type | Field and Description |
|---|---|
private static String |
__DATA_COVERIMAGE |
private static String |
__DATA_CREATION |
private static String |
__DATA_DEFAULT_PROFILE |
private static String |
__DATA_DESCRIPTION |
private static String |
__DATA_INSCRIPTION_STATUS |
private static String |
__DATA_MAILING_LIST |
private static String |
__DATA_MANAGERS |
private static String |
__DATA_MODULES |
private static String |
__DATA_TITLE |
private static String |
__EXPLORER_NODE_NAME |
static String |
DATA_SITES
Metadata name for project 's sites
|
static String |
NODE_TYPE
Project node type name.
|
| Constructor and Description |
|---|
Project(Node node,
String parentPath,
ProjectFactory factory)
Creates a
Project. |
| Modifier and Type | Method and Description |
|---|---|
void |
addModule(String moduleId)
Add a module to the list of activated modules
|
BinaryMetadata |
getCoverImage()
Returns the cover image of the project
|
ZonedDateTime |
getCreationDate()
Retrieves the date of creation.
|
ModifiableModelLessDataHolder |
getDataHolder()
Returns the
DataHolder of this AmetysObject. |
String |
getDefaultProfile()
Get the default profile for new members of the project
|
String |
getDescription()
Retrieves the description.
|
NodeIterator |
getEvents()
Returns the events' nodes
|
Node |
getEventsRootNode()
Returns the node holding the events
|
AmetysObjectIterable<ExplorerNode> |
getExplorerNodes()
Retrieves the explorer nodes.
|
ExplorerNode |
getExplorerRootNode()
Retrieves the explorer nodes.
|
Project.InscriptionStatus |
getInscriptionStatus()
Get the inscription status of the project
|
String |
getMailingList()
Retrieves the mailing list.
|
UserIdentity[] |
getManagers()
Get the project managers user identities
|
String[] |
getModules()
Retrieve the list of activated modules for the project
|
Collection<Site> |
getSites()
Get the sites of the project
|
String |
getTitle()
Retrieves the title.
|
void |
removeDescription()
Remove the description.
|
void |
removeMailingList()
Remove the mailing list.
|
void |
removeModule(String moduleId)
Remove a module from the list of activated modules
|
void |
setCoverImage(InputStream is,
String mimeType,
String filename,
Date lastModifiedDate)
Set the cover image of the site
|
void |
setCreationDate(ZonedDateTime creationDate)
Set the date of creation.
|
void |
setDefaultProfile(String profileId)
Set the default profile for the members of the project
|
void |
setDescription(String description)
Set the description.
|
void |
setInscriptionStatus(String inscriptionStatus)
Set the inscription status of the project
|
void |
setMailingList(String mailingList)
Set the mailing list.
|
void |
setManagers(UserIdentity[] user)
Set the project managers
|
void |
setModules(String[] modules)
Set the list of activated modules for the project
|
void |
setSites(Collection<String> sites)
Set the sites of the project
|
void |
setTitle(String title)
Set the title.
|
addAllowedGroups, addAllowedProfilesForAnonymous, addAllowedProfilesForAnyConnectedUser, addAllowedUsers, addDeniedGroups, addDeniedProfilesForAnonymous, addDeniedProfilesForAnyConnectedUser, addDeniedUsers, createChild, getAllowedGroups, getAllowedProfilesForAnonymous, getAllowedProfilesForAnyConnectedUser, getAllowedProfilesForGroups, getAllowedProfilesForUser, getAllowedProfilesForUsers, getAllowedUsers, getChild, getChildren, getDeniedGroups, getDeniedProfilesForAnonymous, getDeniedProfilesForAnyConnectedUser, getDeniedProfilesForGroups, getDeniedProfilesForUser, getDeniedProfilesForUsers, getDeniedUsers, hasChild, removeAllowedGroups, removeAllowedGroups, removeAllowedProfilesForAnonymous, removeAllowedProfilesForAnyConnectedUser, removeAllowedUsers, removeAllowedUsers, removeDeniedGroups, removeDeniedGroups, removeDeniedProfilesForAnonymous, removeDeniedProfilesForAnyConnectedUser, removeDeniedUsers, removeDeniedUsers_getFactory, _invalidateName, _invalidateParentPath, getId, getMetadataHolder, getName, getNode, getParent, getParentPath, getPath, needsSave, remove, rename, revertChanges, saveChangesequals, hashCode, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetProjectsTreePathgetChild, getChildAt, getChildPosition, getChildren, hasChildgetComposite, getComposite, getRepeater, getRepeater, removeValue, setValue, setValuegetType, getValue, getValue, getValueOfType, getValueOfType, hasValue, isMultiplecopyTo, getDataNamesequals, getId, getName, getParent, getParentPath, getPath, hashCodetoSAX, toSAXdataToSAX, dataToSAX, dataToSAX, dataToSAXgetNodegetMetadataHolderneedsSave, rename, revertChanges, saveChangesremovepublic static final String NODE_TYPE
public static final String DATA_SITES
private static final String __EXPLORER_NODE_NAME
private static final String __DATA_TITLE
private static final String __DATA_DESCRIPTION
private static final String __DATA_MAILING_LIST
private static final String __DATA_CREATION
private static final String __DATA_MANAGERS
private static final String __DATA_MODULES
private static final String __DATA_INSCRIPTION_STATUS
private static final String __DATA_DEFAULT_PROFILE
private static final String __DATA_COVERIMAGE
public Project(Node node, String parentPath, ProjectFactory factory)
Project.node - the node backing this AmetysObject.parentPath - the parent path in the Ametys hierarchy.factory - the ProjectFactory which creates the AmetysObject.public ModifiableModelLessDataHolder getDataHolder()
DataAwareAmetysObjectDataHolder of this AmetysObject.getDataHolder in interface DataAwareAmetysObjectgetDataHolder in interface ModelLessDataAwareAmetysObjectgetDataHolder in interface ModifiableModelLessDataAwareAmetysObjectDataHolder of this AmetysObjectpublic String getTitle() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public void setTitle(String title) throws AmetysRepositoryException
title - the title.AmetysRepositoryException - if an error occurs.public String getDescription() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public void setDescription(String description) throws AmetysRepositoryException
description - the description.AmetysRepositoryException - if an error occurs.public void removeDescription() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public ExplorerNode getExplorerRootNode() throws AmetysRepositoryException
AmetysObjectIterable.AmetysRepositoryException - if an error occurs.public AmetysObjectIterable<ExplorerNode> getExplorerNodes() throws AmetysRepositoryException
AmetysObjectIterable.AmetysRepositoryException - if an error occurs.public String getMailingList() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public void setMailingList(String mailingList) throws AmetysRepositoryException
mailingList - the mailing list.AmetysRepositoryException - if an error occurs.public void removeMailingList() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public ZonedDateTime getCreationDate() throws AmetysRepositoryException
AmetysRepositoryException - if an error occurs.public void setCreationDate(ZonedDateTime creationDate) throws AmetysRepositoryException
creationDate - the date of creationAmetysRepositoryException - if an error occurs.public Node getEventsRootNode() throws RepositoryException
EventHoldergetEventsRootNode in interface EventHolderRepositoryException - if failed to get event holder nodepublic NodeIterator getEvents() throws RepositoryException
EventHoldergetEvents in interface EventHolderRepositoryException - if failed to get events' nodespublic Collection<Site> getSites()
public void setSites(Collection<String> sites)
sites - The names of the sitepublic UserIdentity[] getManagers()
public void setManagers(UserIdentity[] user)
user - The managerspublic String[] getModules()
public void setModules(String[] modules)
modules - The list of modulespublic void addModule(String moduleId)
moduleId - The module idpublic void removeModule(String moduleId)
moduleId - The module idpublic Project.InscriptionStatus getInscriptionStatus()
public void setInscriptionStatus(String inscriptionStatus)
inscriptionStatus - The inscription statuspublic String getDefaultProfile()
public void setDefaultProfile(String profileId)
profileId - The ID of the profilepublic void setCoverImage(InputStream is, String mimeType, String filename, Date lastModifiedDate)
is - The input stream of the cover imagemimeType - The mimetype of the cover imagefilename - The filename of the cover imagelastModifiedDate - The last modified date of the cover imagepublic BinaryMetadata getCoverImage()