001/*
002 * Copyright (c) 2006-2011 Nuxeo SA (http://nuxeo.com/) and others.
003 *
004 * All rights reserved. This program and the accompanying materials
005 * are made available under the terms of the Eclipse Public License v1.0
006 * which accompanies this distribution, and is available at
007 * http://www.eclipse.org/legal/epl-v10.html
008 *
009 * Contributors:
010 *     Nuxeo - initial API and implementation
011 * $Id:LifeCycleState.java 4249 2006-10-16 19:56:10Z janguenot $
012 */
013
014package org.nuxeo.ecm.core.lifecycle;
015
016import java.util.Collection;
017
018/**
019 * Life cycle state.
020 *
021 * @see org.nuxeo.ecm.core.lifecycle.impl.LifeCycleStateImpl
022 * @author <a href="mailto:ja@nuxeo.com">Julien Anguenot</a>
023 */
024public interface LifeCycleState {
025
026    /**
027     * Returns the life cycle state name.
028     *
029     * @return the life cycle state name as a string
030     */
031    String getName();
032
033    /**
034     * Returns the life cycle state descriptions.
035     *
036     * @return the life cycle state description
037     */
038    String getDescription();
039
040    /**
041     * Returns the allowed state transitions.
042     *
043     * @return a collection of string representing the allowed state transitions
044     */
045    Collection<String> getAllowedStateTransitions();
046
047    /**
048     * Returns true if state is a valid initial state
049     */
050    boolean isInitial();
051
052}