001/** 002 * Copyright 2005-2014 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.web; 017 018import java.io.Serializable; 019import java.util.Map; 020 021import org.kuali.rice.kew.api.util.CodeTranslator; 022 023/** 024 * A bean for the web-tier when represents the recipient of an Ad Hoc request. 025 * 026 * @author Kuali Rice Team (rice.collab@kuali.org) 027 */ 028public class AppSpecificRouteRecipient implements Serializable { 029 030 private static final long serialVersionUID = 6587140192756322878L; 031 032 private static Map actionRequestCds; 033 protected String type; 034 protected String actionRequested; 035 protected String id; //can be networkId or groupId (although, currently, it's being treated as principal name or group name) 036 protected String namespaceCode; // Can be a group namespace code or a person name 037 protected String actionRequestId; // The action request ID of the AdHoc route action that was sent for this app specific recipient, if any. 038 039 public String getActionRequested() { 040 return actionRequested; 041 } 042 public void setActionRequested(String actionRequested) { 043 this.actionRequested = actionRequested; 044 } 045 public String getId() { 046 return id; 047 } 048 public void setId(String id) { 049 this.id = id; 050 } 051 public String getType() { 052 return type; 053 } 054 public void setType(String type) { 055 this.type = type; 056 } 057 058 public String getNamespaceCode() { 059 return namespaceCode; 060 } 061 public void setNamespaceCode(String namespaceCode) { 062 this.namespaceCode = namespaceCode; 063 } 064 065 public String getActionRequestId() { 066 return actionRequestId; 067 } 068 069 public void setActionRequestId(String actionRequestId) { 070 this.actionRequestId = actionRequestId; 071 } 072 073 public String getActionRequestedValue(){ 074 actionRequestCds.clear(); 075 actionRequestCds.putAll(CodeTranslator.arLabels); 076 if(getActionRequested() != null && !getActionRequested().trim().equals("")){ 077 return (String) actionRequestCds.get(getActionRequested()); 078 } 079 return null; 080 } 081 082}