Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2003, 2007 s IT Solutions AT Spardat GmbH . All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html Contributors: s IT Solutions AT Spardat GmbH - initial API and implementation /
 
 
 /*
  * Created on 16.05.2003
  */
 package at.spardat.xma.boot.transport;
 
Thrown by Transport, if anything goes wrong in the communication with the server.

Author(s):
s2877
Version:
$Id: CommunicationException.java 2084 2007-11-27 14:53:31Z s3460 $
 
 public class CommunicationException extends IOException {
    
the http-returncode of the failed communication
 
     int returnCode;

    
Constructs an CommunicationException with the specified detail Exception. The message of the detail exception is used as message of the CommunicationException.

Parameters:
exc the detail exception.
 
     public CommunicationException(Exception exc) {
         super(exc.toString());
         initCause(exc);
     }

    
Constructs an CommunicationException with the specified detail message.

Parameters:
message the detail message.
 
     public CommunicationException(String message) {
         super(message);
     }

    
Constructs an CommunicationException with the specified mesage and detail Exception.

Parameters:
message the detail message.
exc the detail exception.
 
     public CommunicationException(String message,Exception exc) {
         super(message);
         initCause(exc);
     }

    
Constructs an CommunicationException with the specified message, detail Exception and Http-Returncode. The message of the CommunicationException is composed of the detail message and the returncode.

Parameters:
message the detail message
exc the detail exception
returnCode the HTTP-Returncode send by the server
 
     public CommunicationException(String message,Exception exc,int returnCode) {
         super(returnCode==0 ? message : message+", return code: "+Integer.toString(returnCode)); //$NON-NLS-1$
         initCause(exc);
         this.=returnCode;
     }

    
Constructs an CommunicationException with the specified detail Exception and Http-Returncode. The message of the CommunicationException is composed of the message of the detail exception and the returncode.

Parameters:
exc the detail exception
returnCode the HTTP-Returncode send by the server
 
     public CommunicationException(Exception exc,int returnCode) {
         super(returnCode==0 ? exc.toString() : exc.toString()+", return code: "+Integer.toString(returnCode)); //$NON-NLS-1$
         initCause(exc);
         this.=returnCode;
     }

    
Constructs an CommunicationException with the specified detail message and Http-Returncode. The message of the CommunicationException is composed of the detail message and the returncode.

Parameters:
message the detail message
returnCode the HTTP-Returncode send by the server
 
    public CommunicationException(String message,int returnCode) {
        super(returnCode==0 ? message : message+", return code: "+Integer.toString(returnCode)); //$NON-NLS-1$
        this.=returnCode;
    }

    
Constructs an CommunicationException with the specified Http-Returncode. The message of the CommunicationException is composed of the returncode.

Parameters:
returnCode the HTTP-Returncode send by the server
    public CommunicationException(int returnCode) {
        super("return code: "+Integer.toString(returnCode)); //$NON-NLS-1$
        this.=returnCode;
    }


    

Returns:
Returns the returnCode.
    public int getReturnCode() {
        return ;
    }
    

Parameters:
returnCode The returnCode to set.
    public void setReturnCode(int returnCode) {
        this. = returnCode;
    }
New to GrepCode? Check out our FAQ X