| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| WarningContainer | 
  | 
  | 1.0;1 | 
| 1 |  /* | |
| 2 |   * Copyright 2007-2009 The Kuali Foundation | |
| 3 |   * | |
| 4 |   * Licensed under the Educational Community License, Version 2.0 (the "License"); | |
| 5 |   * you may not use this file except in compliance with the License. | |
| 6 |   * You may obtain a copy of the License at | |
| 7 |   * | |
| 8 |   * http://www.opensource.org/licenses/ecl2.php | |
| 9 |   * | |
| 10 |   * Unless required by applicable law or agreed to in writing, software | |
| 11 |   * distributed under the License is distributed on an "AS IS" BASIS, | |
| 12 |   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
| 13 |   * See the License for the specific language governing permissions and | |
| 14 |   * limitations under the License. | |
| 15 |   */ | |
| 16 |  package org.kuali.rice.kns.util; | |
| 17 | ||
| 18 |  import java.util.List; | |
| 19 |  import java.util.Set; | |
| 20 | ||
| 21 |  /** | |
| 22 |   * An implementation of {@link MessageContainer} that makes warning messages accessible by the JSP layer  | |
| 23 |   *  | |
| 24 |   * @author Kuali Rice Team (rice.collab@kuali.org) | |
| 25 |   * | |
| 26 |   */ | |
| 27 | public class WarningContainer extends MessageContainer {  | |
| 28 | ||
| 29 |          public WarningContainer(MessageMap errorMap) { | |
| 30 | 0 |                  super(errorMap); | 
| 31 | 0 |          } | 
| 32 | ||
| 33 |          /** | |
| 34 |           * This overridden method ... | |
| 35 |           *  | |
| 36 |           * @see org.kuali.rice.kns.util.MessageContainer#getMessageCount() | |
| 37 |           */ | |
| 38 | @Override  | |
| 39 | public int getMessageCount() {  | |
| 40 | 0 |                  return getMessageMap().getWarningCount(); | 
| 41 | }  | |
| 42 | ||
| 43 | ||
| 44 |          /** | |
| 45 |           * @see org.kuali.rice.kns.util.MessageContainer#getMessagePropertyNames() | |
| 46 |           */ | |
| 47 | @Override  | |
| 48 |          protected Set<String> getMessagePropertyNames() { | |
| 49 | 0 |                  return getMessageMap().getAllPropertiesWithWarnings(); | 
| 50 | }  | |
| 51 | ||
| 52 |          /** | |
| 53 |           * @see org.kuali.rice.kns.util.MessageContainer#getMessagePropertyList() | |
| 54 |           */ | |
| 55 | @Override  | |
| 56 |          public List<String> getMessagePropertyList() { | |
| 57 | 0 |                  return getMessageMap().getPropertiesWithWarnings(); | 
| 58 | }  | |
| 59 | ||
| 60 |          /** | |
| 61 |           * @see org.kuali.rice.kns.util.MessageContainer#getMessagesForProperty(java.lang.String) | |
| 62 |           */ | |
| 63 | @Override  | |
| 64 |          protected List getMessagesForProperty(String propertyName) { | |
| 65 | 0 |                  return getMessageMap().getWarningMessagesForProperty(propertyName); | 
| 66 | }  | |
| 67 | }  |