001/*
002 * This library is part of OpenCms -
003 * the Open Source Content Management System
004 *
005 * Copyright (c) Alkacon Software GmbH & Co. KG (http://www.alkacon.com)
006 *
007 * This library is free software; you can redistribute it and/or
008 * modify it under the terms of the GNU Lesser General Public
009 * License as published by the Free Software Foundation; either
010 * version 2.1 of the License, or (at your option) any later version.
011 *
012 * This library is distributed in the hope that it will be useful,
013 * but WITHOUT ANY WARRANTY; without even the implied warranty of
014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
015 * Lesser General Public License for more details.
016 *
017 * For further information about Alkacon Software GmbH & Co. KG, please see the
018 * company website: http://www.alkacon.com
019 *
020 * For further information about OpenCms, please see the
021 * project website: http://www.opencms.org
022 *
023 * You should have received a copy of the GNU Lesser General Public
024 * License along with this library; if not, write to the Free Software
025 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
026 */
027
028package org.opencms.workplace.list;
029
030/**
031 * Interface for list direct action, that is an action that may be applied
032 * directly on a list item.<p>
033 *
034 * @since 6.0.0
035 */
036public interface I_CmsListDirectAction extends I_CmsListAction {
037
038    /**
039     * Generates a confirmation text div tag, to use in lists where all items use
040     * the same confirmation text.<p>
041     *
042     * @return html code
043     */
044    String confirmationTextHtml();
045
046    /**
047     * Returns the id of the column to use as parameter for the helptext and confirmation message.<p>
048     *
049     * @return the id of the column to use
050     */
051    String getColumnForTexts();
052
053    /**
054     * Returns the current item.<p>
055     *
056     * @return the current item
057     */
058    CmsListItem getItem();
059
060    /**
061     * Generates a help text div tag, to use in lists where all items use the same help text.<p>
062     *
063     * @return html code
064     */
065    String helpTextHtml();
066
067    /**
068     * Sets the id of the column to use as parameter for the helptext and confirmation message.<p>
069     *
070     * @param columnId the id of the column to use
071     */
072    void setColumnForTexts(String columnId);
073
074    /**
075     * Sets the current item, should be called before the <code>{@link #buttonHtml(org.opencms.workplace.CmsWorkplace)}</code> method.<p>
076     *
077     * @param item the item
078     */
079    void setItem(CmsListItem item);
080
081}