01: /*
02: * $Id: MalformedEndpointException.java 10489 2008-01-23 17:53:38Z dfeist $
03: * --------------------------------------------------------------------------------------
04: * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
05: *
06: * The software in this package is published under the terms of the CPAL v1.0
07: * license, a copy of which has been included with this distribution in the
08: * LICENSE.txt file.
09: */
10:
11: package org.mule.api.endpoint;
12:
13: import org.mule.config.i18n.CoreMessages;
14: import org.mule.config.i18n.Message;
15:
16: /**
17: * <code>MalformedEndpointException</code> is thrown by the MuleEndpointURI class
18: * if it fails to parse a Url
19: *
20: * @see org.mule.endpoint.MuleEndpointURI
21: */
22:
23: public class MalformedEndpointException extends EndpointException {
24: /**
25: * Serial version
26: */
27: private static final long serialVersionUID = -3179045414716505094L;
28:
29: /**
30: * @param endpoint the endpoint that could not be parsed
31: */
32: public MalformedEndpointException(String endpoint) {
33: super (CoreMessages.endpointIsMalformed(endpoint));
34: }
35:
36: /**
37: * @param endpoint the endpoint that could not be parsed
38: */
39: public MalformedEndpointException(Message message, String endpoint) {
40: super (CoreMessages.endpointIsMalformed(endpoint)
41: .setNextMessage(message));
42: }
43:
44: /**
45: * @param endpoint the endpoint that could not be parsed
46: * @param cause the exception that cause this exception to be thrown
47: */
48: public MalformedEndpointException(String endpoint, Throwable cause) {
49: super (CoreMessages.endpointIsMalformed(endpoint), cause);
50: }
51:
52: public MalformedEndpointException(Throwable cause) {
53: super(cause);
54: }
55: }
|