com.atlassian.confluence.license.exception.handler
Class CompositeLicenseExceptionHandler

java.lang.Object
  extended by com.atlassian.confluence.license.exception.handler.CompositeLicenseExceptionHandler
All Implemented Interfaces:
LicenseExceptionHandler<java.lang.Exception>

public class CompositeLicenseExceptionHandler
extends java.lang.Object
implements LicenseExceptionHandler<java.lang.Exception>

Ensures that the more specific LicenseExceptionHandler gets asked before.


Field Summary
static org.slf4j.Logger log
           
 
Constructor Summary
CompositeLicenseExceptionHandler(I18NBean i18NBean, java.util.Map<java.lang.Class<? extends java.lang.Exception>,LicenseExceptionHandler<? extends java.lang.Exception>> handlers)
           
 
Method Summary
 java.lang.String handle(java.lang.Exception exception)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

public static final org.slf4j.Logger log
Constructor Detail

CompositeLicenseExceptionHandler

public CompositeLicenseExceptionHandler(I18NBean i18NBean,
                                        java.util.Map<java.lang.Class<? extends java.lang.Exception>,LicenseExceptionHandler<? extends java.lang.Exception>> handlers)
Method Detail

handle

public java.lang.String handle(java.lang.Exception exception)
Specified by:
handle in interface LicenseExceptionHandler<java.lang.Exception>
Parameters:
exception - the exception to translate
Returns:
a default localised message if the exception could not be mapped or a specialised localised message explaining the reason for the exception, return null to indicate that the exception was not handled


Copyright © 2003-2014 Atlassian. All Rights Reserved.