View Javadoc

1   /*
2    * $Id: FilterUnacceptedException.java 22281 2011-06-27 19:45:10Z evangelinamrm $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.api.routing.filter;
12  
13  import org.mule.api.MessagingException;
14  import org.mule.api.MuleEvent;
15  import org.mule.config.i18n.Message;
16  
17  
18  public class FilterUnacceptedException extends MessagingException
19  {
20      private static final long serialVersionUID = -1828111078295716525L;
21      
22      private transient Filter filter;
23  
24      public FilterUnacceptedException(Message message, MuleEvent event, Filter filter)
25      {
26          super(message, event);
27          this.filter = filter;
28          addInfo("Filter", filter.toString());
29      }
30  
31      public FilterUnacceptedException(Message message, MuleEvent event, Filter filter, Throwable cause)
32      {
33          super(message, event, cause);
34          this.filter = filter;
35          addInfo("Filter", filter.toString());
36      }
37  
38      public FilterUnacceptedException(MuleEvent event, Filter filter, Throwable cause)
39      {
40          super(event, cause);
41          this.filter = filter;
42          addInfo("Filter", (filter == null ? "null" : filter.toString()));
43      }
44  
45      public FilterUnacceptedException(Message message, MuleEvent event, Throwable cause)
46      {
47          super(message, event, cause);
48      }
49  
50      public FilterUnacceptedException(Message message, MuleEvent event)
51      {
52          super(message, event);
53      }
54  
55      public Filter getFilter()
56      {
57          return filter;
58      }
59  }