jacquard 1.12.0 by The Web Engineering Factory and Toolworks

uk.co.weft.exceptionhandler
Class BugzillaExceptionHandler

java.lang.Object
  extended byuk.co.weft.htform.ResourceConsumerImpl
      extended byuk.co.weft.exceptionhandler.JustWhingeExceptionHandler
          extended byuk.co.weft.exceptionhandler.BugzillaExceptionHandler
All Implemented Interfaces:
ExceptionHandler, ResourceConsumer

public class BugzillaExceptionHandler
extends JustWhingeExceptionHandler

An exception handler which generates a form already prefilled with a Bugzilla bug report. This class, and consequently any subclasses, knows about the following initialisation parameters:

bugzilla_enter_bug_url
URL: The URL of the enter_bug.cgi script on the bugzilla installation I report to. Not optional. No default.
bugzilla_product_name
String: the product name I should report to that bugzilla installation. Optional. Defaults to jacquard.
bugzilla_product_version
String: the product version I should report to that bugzilla installation. Optional. Defaults to unknown.


Field Summary
protected  boolean debug
          whether or not my servlet is in debug mode
protected  java.lang.String enterBugURL
          The URL of enter_bug.cgi of the Bugzilla I talk to
static java.lang.String ENTERBUGURLCONFIGTOKEN
          a token on which I shall look for the value of enterBugURL in my configuration and resources
protected  java.lang.String password
          experimental: the bugzilla password to log in with
static java.lang.String PASSWORDCONFIGTOKEN
          a token on which I shall look for my product version in my configuration and resources
protected  java.lang.String product
          The product name of the product I am, as known to that Bugzilla
static java.lang.String PRODUCTNAMECONFIGTOKEN
          a token on which I shall look for my product name in my configuration and resources
static java.lang.String PRODUCTVERSIONCONFIGTOKEN
          a token on which I shall look for my product version in my configuration and resources
protected  java.lang.String username
          experimental: the bugzilla username to login with
static java.lang.String USERNAMECONFIGTOKEN
          a token on which I shall look for my bugzilla username in my configuration and resources
protected  java.lang.String version
          The product version of the product I am, as known to that Bugzilla
 
Fields inherited from class uk.co.weft.htform.ResourceConsumerImpl
resourceBundleName
 
Fields inherited from interface uk.co.weft.htform.ResourceConsumer
RESOURCEBUNDLEMAGICTOKEN
 
Constructor Summary
BugzillaExceptionHandler()
           
 
Method Summary
 void init(Context config)
          Locate all the information I need to communicate with the relevent Bugzilla
 void whinge(javax.servlet.ServletOutputStream out, java.lang.Exception e, Context context)
          output a form which invites the user to send a bug report to my bugzilla
 
Methods inherited from class uk.co.weft.exceptionhandler.JustWhingeExceptionHandler
printLabel, printWidget, printWidget
 
Methods inherited from class uk.co.weft.htform.ResourceConsumerImpl
getContextOrResource, getResource, getResourceOrContext, getResourceString, grs, grs
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ENTERBUGURLCONFIGTOKEN

public static final java.lang.String ENTERBUGURLCONFIGTOKEN
a token on which I shall look for the value of enterBugURL in my configuration and resources

See Also:
Constant Field Values

PRODUCTNAMECONFIGTOKEN

public static final java.lang.String PRODUCTNAMECONFIGTOKEN
a token on which I shall look for my product name in my configuration and resources

See Also:
Constant Field Values

PRODUCTVERSIONCONFIGTOKEN

public static final java.lang.String PRODUCTVERSIONCONFIGTOKEN
a token on which I shall look for my product version in my configuration and resources

See Also:
Constant Field Values

USERNAMECONFIGTOKEN

public static final java.lang.String USERNAMECONFIGTOKEN
a token on which I shall look for my bugzilla username in my configuration and resources

See Also:
Constant Field Values

PASSWORDCONFIGTOKEN

public static final java.lang.String PASSWORDCONFIGTOKEN
a token on which I shall look for my product version in my configuration and resources

See Also:
Constant Field Values

enterBugURL

protected java.lang.String enterBugURL
The URL of enter_bug.cgi of the Bugzilla I talk to


password

protected java.lang.String password
experimental: the bugzilla password to log in with


product

protected java.lang.String product
The product name of the product I am, as known to that Bugzilla


username

protected java.lang.String username
experimental: the bugzilla username to login with


version

protected java.lang.String version
The product version of the product I am, as known to that Bugzilla


debug

protected boolean debug
whether or not my servlet is in debug mode

Constructor Detail

BugzillaExceptionHandler

public BugzillaExceptionHandler()
Method Detail

init

public void init(Context config)
          throws InitialisationException
Locate all the information I need to communicate with the relevent Bugzilla

Specified by:
init in interface ExceptionHandler
Overrides:
init in class JustWhingeExceptionHandler
Throws:
InitialisationException

whinge

public void whinge(javax.servlet.ServletOutputStream out,
                   java.lang.Exception e,
                   Context context)
            throws javax.servlet.ServletException
output a form which invites the user to send a bug report to my bugzilla

Specified by:
whinge in interface ExceptionHandler
Overrides:
whinge in class JustWhingeExceptionHandler
Throws:
javax.servlet.ServletException

jacquard 1.12.0 by The Web Engineering Factory and Toolworks