001/** 002 * Copyright 2005-2017 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.kew.actionlist; 017 018import org.kuali.rice.kew.api.action.ActionItem; 019import org.kuali.rice.kew.api.action.ActionSet; 020import org.kuali.rice.kew.api.actionlist.DisplayParameters; 021 022 023 024/** 025 * The default implementation of a CustomActionListAttribute. Shows only FYI actions. 026 * 027 * @author Kuali Rice Team (rice.collab@kuali.org) 028 */ 029public class DefaultCustomActionListAttribute implements CustomActionListAttribute { 030 031 private static final long serialVersionUID = 6776164670024486696L; 032 033 /** 034 * Sets up the default ActionSet which includes only FYIs. 035 */ 036 private static ActionSet DEFAULT_LEGAL_ACTIONS = ActionSet.Builder.create().build(); 037 static { 038 DEFAULT_LEGAL_ACTIONS.addFyi(); 039 } 040 041 @Override 042 public ActionSet getLegalActions(String principalId, ActionItem actionItem) throws Exception { 043 return DEFAULT_LEGAL_ACTIONS; 044 } 045 046 @Override 047 public DisplayParameters getDocHandlerDisplayParameters(String principalId, ActionItem actionItem) throws Exception { 048 return null; 049 } 050 051}