当前位置: 首页>>代码示例>>Java>>正文


Java ExceptionHandler类代码示例

本文整理汇总了Java中javax.faces.context.ExceptionHandler的典型用法代码示例。如果您正苦于以下问题:Java ExceptionHandler类的具体用法?Java ExceptionHandler怎么用?Java ExceptionHandler使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ExceptionHandler类属于javax.faces.context包,在下文中一共展示了ExceptionHandler类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler()
{
    lazyInit();

    ExceptionHandler exceptionHandler = this.wrappedFacesContext.getExceptionHandler();

    if (this.bridgeExceptionHandlerActivated)
    {
        exceptionHandler = new BridgeExceptionHandlerWrapper(
            exceptionHandler, this.beanManager, this.bridgeExceptionQualifier);
    }
    
    if (this.defaultErrorViewExceptionHandlerActivated)
    {
        exceptionHandler = new DefaultErrorViewAwareExceptionHandlerWrapper(exceptionHandler);
    }

    return exceptionHandler;
}
 
开发者ID:apache,项目名称:deltaspike,代码行数:21,代码来源:DeltaSpikeFacesContextWrapper.java

示例2: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
    ExceptionHandler result = parent.getExceptionHandler();
    result = new ViewExpiredExceptionExceptionHandler(result);
 
    return result;
}
 
开发者ID:c-ruttkies,项目名称:MetFragRelaunched,代码行数:8,代码来源:ViewExpiredExceptionExceptionHandlerFactory.java

示例3: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
    
    ExceptionHandler result = parent.getExceptionHandler();
    result = new ViewExpiredExceptionExceptionHandler(result);

    return result;
}
 
开发者ID:drifted-in,项目名称:genopro-tools,代码行数:9,代码来源:ViewExpiredExceptionExceptionHandlerFactory.java

示例4: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
    //wrap the exception handler in new one
    ExceptionHandler result = parent.getExceptionHandler();
    result = new ViewExpiredExceptionHandler(result);
 
    return result;

}
 
开发者ID:vodev,项目名称:vocloud,代码行数:10,代码来源:ViewExpiredExceptionExceptionHandlerFactory.java

示例5: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public synchronized ExceptionHandler getExceptionHandler() {
    if (tracker == null) {
        ServletContext context = (ServletContext) FacesContext.getCurrentInstance().getExternalContext().getContext();
        BundleContext ctx = (BundleContext) context.getAttribute("osgi-bundlecontext");
        if (ctx == null) {
            ctx = FrameworkUtil.getBundle(getClass()).getBundleContext();
        }
        tracker = new ServiceTracker<>(ctx, TransactionManager.class, null);
        tracker.open();
    }
    return new JtaExceptionHandler(parent.getExceptionHandler(), tracker);
}
 
开发者ID:arievanwi,项目名称:osgi.ee,代码行数:14,代码来源:JtaExceptionHandlerFactory.java

示例6: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {

	ExceptionHandler result = new KarakuJSFExceptionHandler(
			parent.getExceptionHandler());
	return result;
}
 
开发者ID:fpuna-cia,项目名称:karaku,代码行数:8,代码来源:KarakuJSFExceptionHandlerFactory.java

示例7: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
    if(cached == null) {
        cached = new ShowcaseExceptionHandler(base.getExceptionHandler());
    }
    
    return cached;
}
 
开发者ID:websphere,项目名称:PrimefacesShowcase,代码行数:9,代码来源:ShowcaseExceptionHandlerFactory.java

示例8: initFacesContext

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
protected void initFacesContext()
{
    FacesContextFactory facesContextFactory =
            (FacesContextFactory) FactoryFinder.getFactory(FactoryFinder.FACES_CONTEXT_FACTORY);
    this.facesContext = facesContextFactory.getFacesContext(
            this.servletContext, this.request, this.response, this.lifecycle);

    ((MockFacesContext) this.facesContext).setApplication(this.application);
    ExceptionHandler exceptionHandler = ((ExceptionHandlerFactory)
            FactoryFinder.getFactory(FactoryFinder.EXCEPTION_HANDLER_FACTORY)).getExceptionHandler();
    this.facesContext.setExceptionHandler(exceptionHandler);

    ((MockFacesContext) this.facesContext).setExternalContext(
            new MockExternalContext(this.servletContext, this.request, this.response));
}
 
开发者ID:apache,项目名称:deltaspike,代码行数:16,代码来源:MockedJsf2TestContainer.java

示例9: BridgeExceptionHandlerWrapper

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
public BridgeExceptionHandlerWrapper(ExceptionHandler wrapped,
                                     BeanManager beanManager,
                                     Annotation exceptionQualifier)
{
    this.wrapped = wrapped;
    this.beanManager = beanManager;
    this.exceptionQualifier = exceptionQualifier;
}
 
开发者ID:apache,项目名称:deltaspike,代码行数:9,代码来源:BridgeExceptionHandlerWrapper.java

示例10: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
    ExceptionHandler parentHandler = getWrapped().getExceptionHandler();
    return new DefaultExceptionHandler(parentHandler);
}
 
开发者ID:hantsy,项目名称:javaee8-jsf-sample,代码行数:6,代码来源:DefaultExceptionHandlerFactory.java

示例11: DefaultExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
public DefaultExceptionHandler(ExceptionHandler wrapped) {
    super(wrapped);
}
 
开发者ID:hantsy,项目名称:javaee8-jsf-sample,代码行数:4,代码来源:DefaultExceptionHandler.java

示例12: CustomExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
public CustomExceptionHandler(ExceptionHandler exceptionHandler) {
    this.wrapped = exceptionHandler;
}
 
开发者ID:adminfaces,项目名称:admin-template,代码行数:4,代码来源:CustomExceptionHandler.java

示例13: getWrapped

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getWrapped() {
    return wrapped;
}
 
开发者ID:adminfaces,项目名称:admin-template,代码行数:5,代码来源:CustomExceptionHandler.java

示例14: getExceptionHandler

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
@Override
public ExceptionHandler getExceptionHandler() {
	return new CustomExceptionHandler(this.parent.getExceptionHandler());
}
 
开发者ID:adminfaces,项目名称:admin-template,代码行数:5,代码来源:CustomExceptionHandlerFactory.java

示例15: JsfExceptionHandlerWrapper

import javax.faces.context.ExceptionHandler; //导入依赖的package包/类
public JsfExceptionHandlerWrapper(ExceptionHandler exceptionHandler) {
	this.wrappedExceptionHandler = exceptionHandler;
}
 
开发者ID:marcelothebuilder,项目名称:webpedidos,代码行数:4,代码来源:JsfExceptionHandlerWrapper.java


注:本文中的javax.faces.context.ExceptionHandler类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。