All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.adobe.aemds.guide.service.GuideProgressiveStrategy Maven / Gradle / Ivy

/************************************************************************
 *
 * ADOBE CONFIDENTIAL
 * __________________
 *
 * Copyright 2014 Adobe Systems Incorporated
 * All Rights Reserved.
 *
 * NOTICE:  All information contained herein is, and remains
 * the property of Adobe Systems Incorporated and its suppliers,
 * if any.  The intellectual and technical concepts contained
 * herein are proprietary to Adobe Systems Incorporated and its
 * suppliers and may be covered by U.S. and Foreign Patents,
 * patents in process, and are protected by trade secret or copyright law.
 * Dissemination of this information or reproduction of this material
 * is strictly forbidden unless prior written permission is obtained
 * from Adobe Systems Incorporated.
 *************************************************************************/

package com.adobe.aemds.guide.service;

import com.adobe.aemds.guide.progressive.GuideProgressiveCompletionInfo;
import com.adobe.aemds.guide.progressive.GuideProgressiveSectionInfo;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

/**
 * @pad.exclude Exclude from Published API.
 */
public interface GuideProgressiveStrategy {
    /**
     * Returns the name which is unique for a strategy
     * @return name of the strategy
     */
    public String getName();

    /**
     * Returns the string which briefly describes the strategy
     * @return display name of the progressive strategy
     */
    public String getDisplayName();

    /**
     * Returns the string which describes the type of service
     * If type is static, then it means that the ordering of section is known prior
     * If it is dynamic, then the ordering is not known
     *
     * @return  service type which can be "static" or "dynamic"
     */
    public String getServiceType();

    /**
     * Returns the list of sections. This list contains GuideProgressiveSectionInfo and GuideProgressiveCompletionSectionInfo
     * object.
     * In case of static service type, it would give the list of all sections but in case of dynamic it would give
     * only one section
     *
     * @param paramMap Represent the list of properties available from strategy's dialog
     * @return list representing all sections
     */
    public List getAllSections(Map paramMap);

    /**
     * Returns:
     *      first section in case the currentSectionId is null or empty
     *      next section if currentSectionId not null and not empty
     *      null if penultimate section, that is next would be completion section
     * @param afPath
     * @param currentSectionId
     * @param data
     * @return next section
     * @see GuideProgressiveSectionInfo
     */
    public GuideProgressiveSectionInfo getNextSection(String afPath, String currentSectionId, Map data);

    /**
     * Returns the completion section of strategy
     * @param afpath
     * @param data
     * @return completion section for the given adaptive form path
     * @see GuideProgressiveCompletionInfo
     */
    public GuideProgressiveCompletionInfo getCompletionSection(String afpath, Map data);
}