本文整理汇总了Java中com.vaadin.server.ErrorHandler类的典型用法代码示例。如果您正苦于以下问题:Java ErrorHandler类的具体用法?Java ErrorHandler怎么用?Java ErrorHandler使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ErrorHandler类属于com.vaadin.server包,在下文中一共展示了ErrorHandler类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setErrorHandler
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
@Override
protected void setErrorHandler() {
nroSiniestro.setErrorHandler(new ErrorHandler() {
private static final long serialVersionUID = 4325669635885170314L;
@Override
public void error(com.vaadin.server.ErrorEvent event) {
log.debug("Ocurrio un error al levantar los parametros de busqueda.");
nroSiniestro.setValue(null);
tableSiniestros.removeAllItems();
btnExportar.setEnabled(false);
}
});
}
示例2: init
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
/**
* Adds a default transaction listener.
*/
@Override
public void init() {
final LegacyApplication app = this;
VaadinSession.getCurrent().setErrorHandler(new ErrorHandler() {
private static final long serialVersionUID = 1L;
@Override
public void error(ErrorEvent event) {
Utils.terminalError(event, app);
}
});
if(!Db.isInitialized()) {
logger.warn("No TransactionListener added: Database is not initialized. You can initialize a database configuring a new 'DefaultTransactionListener' in your web.xml and adding a 'configuration.properties' file to your classpath.");
}
VaadinSession.getCurrent().setAttribute("application", this);
}
示例3: setErrorHandler
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
private void setErrorHandler() {
// TODO Auto-generated method stub
txtNombre.setErrorHandler(new ErrorHandler() {
private static final long serialVersionUID = -7866511259549430845L;
@Override
public void error(com.vaadin.server.ErrorEvent event) {
txtNombre.setValue(null);
btnExportar.setEnabled(false);
}
});
}
示例4: callErrorHandler
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
/**
* Call the session's {@link ErrorHandler}, if it has one, with the given
* exception wrapped in an {@link ErrorEvent}.
*/
private void callErrorHandler(VaadinSession session, Exception e) {
try {
ErrorHandler errorHandler = ErrorEvent.findErrorHandler(session);
if (errorHandler != null) {
errorHandler.error(new ErrorEvent(e));
}
} catch (Exception ex) {
// Let's not allow error handling to cause trouble; log fails
getLogger().log(Level.WARNING, "ErrorHandler call failed", ex);
}
}
示例5: AbstractRunningEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
protected AbstractRunningEvent(ErrorHandler errorHandler) {
super(errorHandler);
}
示例6: FinishBranchEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public FinishBranchEvent(ErrorHandler errorHandler) {
super(errorHandler);
}
示例7: StartTestEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public StartTestEvent(SimpleTest test, ErrorHandler errorHandler) {
super(errorHandler);
this.test = test;
}
示例8: ErrorTestEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public ErrorTestEvent(ErrorHandler errorHandler) {
super(errorHandler);
}
示例9: AfterFinishSlideEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public AfterFinishSlideEvent(Direction direction, ErrorHandler errorHandler) {
super(errorHandler);
this.direction = direction;
}
示例10: AfterPrepareTestEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public AfterPrepareTestEvent(SimpleTest test, ErrorHandler errorHandler) {
super(errorHandler);
this.test = test;
}
示例11: CloseTestEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public CloseTestEvent(ErrorHandler errorHandler) {
super(errorHandler);
}
示例12: AfterRenderContentEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public AfterRenderContentEvent(Component component, ErrorHandler errorHandler) {
super(component, errorHandler);
}
示例13: AbstractUserEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
protected AbstractUserEvent(ErrorHandler errorHandler) {
super(errorHandler);
}
示例14: ActionEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public ActionEvent(Action action, ErrorHandler errorHandler) {
super(errorHandler);
this.action = action;
}
示例15: ContinueTestEvent
import com.vaadin.server.ErrorHandler; //导入依赖的package包/类
public ContinueTestEvent(SimpleTest test, ErrorHandler errorHandler) {
super(errorHandler);
this.test = test;
}