⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fileattachmentreplicator.java

📁 国外的一套开源CRM
💻 JAVA
字号:
/*
 * 
 * Copyright (c) 2004 SourceTap - www.sourcetap.com
 *
 *  The contents of this file are subject to the SourceTap Public License 
 * ("License"); You may not use this file except in compliance with the 
 * License. You may obtain a copy of the License at http://www.sourcetap.com/license.htm
 * Software distributed under the License is distributed on an  "AS IS"  basis,
 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
 * the specific language governing rights and limitations under the License.
 *
 * The above copyright notice and this permission notice shall be included
 * in all copies or substantial portions of the Software.
 *
 */

package com.sourcetap.sfa.replication;

import org.ofbiz.entity.GenericValue;


/**
 * This class is used for replication of the FileAttachment entity. <P>
 *
 * @author  <a href='mailto:jnutting@sourcetap.com'>John Nutting</a>
 */
public class FileAttachmentReplicator extends EntityReplicator {
	public static final String module = FileAttachmentReplicator.class.getName();

    /**
     * This method replicates all instances for all related entities. <P>
     *
     * When completed, this method will override the ancestor to copy the
     * file for the passed-in FileAttachment record from the master server
     * to the local server.
     *
     * @author  <a href='mailto:jnutting@sourcetap.com'>John Nutting</a>
     *
     * @param mainInstance Main entity instance for which related entities will be replicated
     *
     * @return Status.  Possible values: STATUS_CONTINUE, STATUS_ERROR, STATUS_CANCELED
     */
    public int replicateAllRelated(GenericValue mainInstance) {

        // Need to insert code here to copy the file that goes with this
        // FileAttachment record.
        return STATUS_CONTINUE;
    }

    /**
     * This method removes all instances for all related entities. <P>
     *
     * When completed, this method will override the ancestor to remove the
     * file for the passed-in FileAttachment record from the local server.
     *
     * @author  <a href='mailto:jnutting@sourcetap.com'>John Nutting</a>
     *
     * @param localInstance Local entity from which related entity instances are to be removed
     *
     * @return Status.  Possible values: STATUS_CONTINUE, STATUS_ERROR, STATUS_CANCELED
     */
    public int removeAllRelated(GenericValue localInstance) {

        // Need to insert code here to remove the file that goes with this
        // FileAttachment record.
        return STATUS_CONTINUE;
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -