/Users/richardallenbair/Documents/Source/Projects/nonsense/swingx/src/beaninfo/CompoundErrorReporter_API.java |
/* * $Id: CompoundErrorReporter_API.html 1362 2006-08-24 20:06:25Z rbair $ * * Copyright 2004 Sun Microsystems, Inc., 4150 Network Circle, * Santa Clara, California 95054, U.S.A. All rights reserved. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ package org.jdesktop.swingx.error; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import org.jdesktop.swingx.JavaBean; /** * <p>An {@link ErrorReporter} that delegates to one or more other * <code>ErrorReporter</code> instances. For example, using this class, you can * send errors both to a {@link LogErrorReporter} and an {@link EmailErrorReporter}.</p> * * @author rbair */ public class CompoundErrorReporter extends JavaBean implements ErrorReporter { /** Creates a new instance of CompoundErrorReporter */ public CompoundErrorReporter(); /** * Sets the array of reporters to delegate to. * * @param reporters an array of reporters to delegate to. May be null. If null, * this param is treated as an empty array. */ public void setReporters(ErrorReporter... reporters); /** * Gets the array of reporters that this CompoundReporter delegates to. This * is a defensive copy. * * @return an array of reporter object. This is never null. */ public final ErrorReporter[] getReporters(); /** * @inheritDoc */ public void reportError(ErrorInfo info); }