Class LinksCopyUpdater
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.linkdirectory.repository.LinksCopyUpdater
- All Implemented Interfaces:
LogEnabled
,CopyUpdater
,Serviceable
Update
DefaultLink
attribute targeting AmetysObject
related to the original site-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected DirectoryHelper
the directory helperprotected ExplorerResourcesDAO
the explorer DAOprotected AmetysObjectResolver
the ametys object resolver -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String
Get the updated page id.protected String
_getResource
(String initialResourceId, Site initialSite, Site createdSite) Get the updated resource id.void
service
(ServiceManager manager) void
updateContent
(Site initialSite, Site createdSite, Content initialContent, Content createdContent) Update content after copy sitevoid
updatePage
(Site initialSite, Site createdSite, Page page) Update page after copy sitevoid
updateSite
(Site initialSite, Site createdSite) Update site after copy siteMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
_resolver
the ametys object resolver -
_directoryHelper
the directory helper -
_explorerDAO
the explorer DAO
-
-
Constructor Details
-
LinksCopyUpdater
public LinksCopyUpdater()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
updateSite
Description copied from interface:CopyUpdater
Update site after copy site- Specified by:
updateSite
in interfaceCopyUpdater
- Parameters:
initialSite
- the original sitecreatedSite
- the created site
-
_getPage
Get the updated page id.- Parameters:
initialPageId
- the initial page idinitialSite
- the initial sitecreatedSite
- the newly created site- Returns:
- the updated id.
-
_getResource
Get the updated resource id.- Parameters:
initialResourceId
- the initial resource idinitialSite
- the initial sitecreatedSite
- the newly created site- Returns:
- the updated id
-
updatePage
Description copied from interface:CopyUpdater
Update page after copy site- Specified by:
updatePage
in interfaceCopyUpdater
- Parameters:
initialSite
- the original sitecreatedSite
- the created sitepage
- the new page
-
updateContent
public void updateContent(Site initialSite, Site createdSite, Content initialContent, Content createdContent) Description copied from interface:CopyUpdater
Update content after copy site- Specified by:
updateContent
in interfaceCopyUpdater
- Parameters:
initialSite
- the initial sitecreatedSite
- the created siteinitialContent
- the initial contentcreatedContent
- the new content
-