1 package org.nuiton.validator.bean.list; 2 /* 3 * #%L 4 * Nuiton Validator 5 * %% 6 * Copyright (C) 2013 - 2014 Code Lutin, Tony Chemit 7 * %% 8 * This program is free software: you can redistribute it and/or modify 9 * it under the terms of the GNU Lesser General Public License as 10 * published by the Free Software Foundation, either version 3 of the 11 * License, or (at your option) any later version. 12 * 13 * This program is distributed in the hope that it will be useful, 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 * GNU General Lesser Public License for more details. 17 * 18 * You should have received a copy of the GNU General Lesser Public 19 * License along with this program. If not, see 20 * <http://www.gnu.org/licenses/lgpl-3.0.html>. 21 * #L% 22 */ 23 24 import org.nuiton.validator.NuitonValidatorScope; 25 import org.nuiton.validator.bean.AbstractValidatorEvent; 26 27 /** 28 * Event to be fired when some messages changed on a given field / scope of a bean. 29 * 30 * @author Tony Chemit - chemit@codelutin.com 31 * @since 2.5.2 32 */ 33 public class BeanListValidatorEvent extends AbstractValidatorEvent<BeanListValidator<?>> { 34 35 private static final long serialVersionUID = 1L; 36 37 /** the bean on which event occurs. */ 38 protected Object bean; 39 40 public BeanListValidatorEvent(BeanListValidator<?> source, 41 Object bean, 42 String field, 43 NuitonValidatorScope scope, 44 String[] messagestoAdd, 45 String[] messagestoDelete) { 46 super(source, field, scope, messagestoAdd, messagestoDelete); 47 this.bean = bean; 48 } 49 50 public Object getBean() { 51 return bean; 52 } 53 54 }