hudson.model
Class Failure

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by hudson.model.Failure
All Implemented Interfaces:
Serializable, org.kohsuke.stapler.HttpResponse

public class Failure
extends RuntimeException
implements org.kohsuke.stapler.HttpResponse

Represents an error induced by user, encountered during HTTP request processing.

The error page is rendered into HTML, but without a stack trace. So only use this exception when the error condition is anticipated by the program, and where we nor users don't need to see the stack trace to figure out the root cause.

Since:
1.321
Author:
Kohsuke Kawaguchi
See Also:
Serialized Form

Constructor Summary
Failure(String message)
           
Failure(String message, boolean pre)
           
 
Method Summary
 void generateResponse(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp, Object node)
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Failure

public Failure(String message)

Failure

public Failure(String message,
               boolean pre)
Method Detail

generateResponse

public void generateResponse(org.kohsuke.stapler.StaplerRequest req,
                             org.kohsuke.stapler.StaplerResponse rsp,
                             Object node)
                      throws IOException,
                             javax.servlet.ServletException
Specified by:
generateResponse in interface org.kohsuke.stapler.HttpResponse
Throws:
IOException
javax.servlet.ServletException


Copyright © 2004-2013. All Rights Reserved.