001/*
002 *  Copyright 2011 Anyware Services
003 *
004 *  Licensed under the Apache License, Version 2.0 (the "License");
005 *  you may not use this file except in compliance with the License.
006 *  You may obtain a copy of the License at
007 *
008 *      http://www.apache.org/licenses/LICENSE-2.0
009 *
010 *  Unless required by applicable law or agreed to in writing, software
011 *  distributed under the License is distributed on an "AS IS" BASIS,
012 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013 *  See the License for the specific language governing permissions and
014 *  limitations under the License.
015 */
016package org.ametys.web.site;
017
018import org.ametys.cms.repository.Content;
019import org.ametys.web.repository.page.Page;
020import org.ametys.web.repository.site.Site;
021
022/**
023 * Interface to update contents or pages after a copy
024 *
025 */
026public interface CopyUpdater
027{
028    /**
029     * Update content after copy site
030     * @param initialSite the initial site
031     * @param createdSite the created site
032     * @param initialContent the initial content
033     * @param createdContent the new content
034     */
035    public void updateContent (Site initialSite, Site createdSite, Content initialContent, Content createdContent);
036    
037    /**
038     * Update page after copy site
039     * @param initialSite the original site
040     * @param createdSite the created site
041     * @param page the new page
042     */
043    public void updatePage (Site initialSite, Site createdSite, Page page);
044    
045    /**
046     * Update site after copy site
047     * @param initialSite the original site
048     * @param createdSite the created site
049     */
050    public void updateSite (Site initialSite, Site createdSite);
051}