001/**
002 * Copyright 2005-2018 The Kuali Foundation
003 *
004 * Licensed under the Educational Community 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.opensource.org/licenses/ecl2.php
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.kuali.rice.krad.uif.lifecycle;
017
018import org.kuali.rice.krad.uif.UifConstants;
019import org.kuali.rice.krad.uif.lifecycle.ViewLifecycle.LifecycleEvent;
020
021/**
022 * Lifecycle phase processing task for initializing a component.
023 *
024 * <p>
025 * During the initialize phase each component of the tree is invoked to setup state based on the
026 * configuration and request options.
027 * </p>
028 *
029 * <p>
030 * The initialize phase is only called once per <code>View</code> lifecycle
031 * </p>
032 *
033 * <p>
034 * Note the <code>View</code> instance also contains the context Map that was created based on the
035 * parameters sent to the view service
036 * </p>
037 *
038 * @author Kuali Rice Team (rice.collab@kuali.org)
039 */
040public class InitializeComponentPhase extends ViewLifecyclePhaseBase {
041
042    /**
043     * {@inheritDoc}
044     *
045     * @return UifConstants.ViewPhases.INITIALIZE
046     */
047    @Override
048    public String getViewPhase() {
049        return UifConstants.ViewPhases.INITIALIZE;
050    }
051
052    /**
053     * {@inheritDoc}
054     * return UifConstants.ViewStatus.CREATED
055     */
056    @Override
057    public String getStartViewStatus() {
058        return UifConstants.ViewStatus.CREATED;
059    }
060
061    /**
062     * {@inheritDoc}
063     *
064     * @return UifConstants.ViewStatus.INITIALIZED
065     */
066    @Override
067    public String getEndViewStatus() {
068        return UifConstants.ViewStatus.INITIALIZED;
069    }
070
071    /**
072     * {@inheritDoc}
073     */
074    @Override
075    public LifecycleEvent getEventToNotify() {
076        return null;
077    }
078
079}