public void validate(FacesContext context, UIComponent component, Object value) throws ValidatorException { if (null == context || null == component) { throw new NullPointerException(); } try { methodBinding.invoke(context, new Object[] {context, component, value}); } catch (EvaluationException ee) { Throwable cause = this.getExpectedCause(ValidatorException.class, ee); if (cause instanceof ValidatorException) { throw ((ValidatorException) cause); } if (cause instanceof RuntimeException) { throw ((RuntimeException) cause); } throw new IllegalStateException(ee.getMessage()); } }
/** * @throws NullPointerException {@inheritDoc} * @throws AbortProcessingException {@inheritDoc} */ public void processValueChange(ValueChangeEvent actionEvent) throws AbortProcessingException { if (actionEvent == null) { throw new NullPointerException(); } try { FacesContext context = FacesContext.getCurrentInstance(); methodBinding.invoke(context, new Object[] {actionEvent}); } catch (EvaluationException ee) { Throwable cause = this.getExpectedCause(AbortProcessingException.class, ee); if (cause instanceof AbortProcessingException) { throw ((AbortProcessingException) cause); } if (cause instanceof RuntimeException) { throw ((RuntimeException) cause); } throw new IllegalStateException(ee.getMessage()); } }
@SuppressWarnings("deprecation") private String getNavigationOutcome(FacesContext context, MethodBinding binding) { if (binding != null) { try { Object invokeResult; if ((invokeResult = binding.invoke(context, null)) != null) { return invokeResult.toString(); } // else, default to null, as returned at the end } catch (MethodNotFoundException e) { if (LOGGER.isLoggable(FINE)) { LOGGER.log(FINE, e.getMessage(), e); } throw new FacesException(binding.getExpressionString() + ": " + e.getMessage(), e); } catch (EvaluationException e) { if (LOGGER.isLoggable(FINE)) { LOGGER.log(FINE, e.getMessage(), e); } throw new FacesException(binding.getExpressionString() + ": " + e.getMessage(), e); } } return null; }
@SuppressWarnings("deprecation") private String getNavigationOutcome(FacesContext context, MethodBinding binding) { if (binding != null) { try { Object invokeResult; if ((invokeResult = binding.invoke(context, null)) != null) { return invokeResult.toString(); } // else, default to null, as returned at the end } catch (MethodNotFoundException e) { if (LOGGER.isLoggable(FINE)) { LOGGER.log(FINE, e.getMessage(), e); } throw new FacesException(binding.getExpressionString() + ": " + e.getMessage(), e); } catch (EvaluationException e) { if (LOGGER.isLoggable(FINE)) { LOGGER.log(FINE, e.getMessage(), e); } throw new FacesException(binding.getExpressionString() + ": " + e.getMessage(), e); } } return null; }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.MethodNotFoundException e) { throw new MethodNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.MethodNotFoundException e) { throw new MethodNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.MethodNotFoundException e) { throw new MethodNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.PropertyNotFoundException e) { throw new PropertyNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
private <T> T invoke(Invoker<T> invoker) { try { return invoker.invoke(); } catch (javax.faces.el.MethodNotFoundException e) { throw new MethodNotFoundException(e.getMessage(), e); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e); } }
public boolean isReadOnly(ELContext context, Object base, Object property) { if (property == null) { return true; } try { context.setPropertyResolved(true); if (base == null) { return false; // what can I do? } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().isReadOnly(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().isReadOnly(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }
public Class getType(ELContext context, Object base, Object property) { if (property == null) { return null; } try { context.setPropertyResolved(true); if (base == null) { Object obj = this.getVariableResolver().resolveVariable( faces, property.toString()); return (obj != null) ? obj.getClass() : null; } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().getType(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().getType(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }
public boolean isReadOnly(ELContext context, Object base, Object property) { if (property == null) { return true; } try { context.setPropertyResolved(true); if (base == null) { return false; // what can I do? } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().isReadOnly(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().isReadOnly(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }
@Override public boolean isReadOnly(ELContext context, Object base, Object property) { if (property == null) { return true; } try { context.setPropertyResolved(true); if (base == null) { return false; // what can I do? } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().isReadOnly(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().isReadOnly(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }
public Object getValue(ELContext context, Object base, Object property) { if (property == null) { return null; } try { context.setPropertyResolved(true); if (base == null) { return this.getVariableResolver().resolveVariable(faces, property.toString()); } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().getValue(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().getValue(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }
public Object getValue(ELContext context, Object base, Object property) { if (property == null) { return null; } try { context.setPropertyResolved(true); if (base == null) { return this.getVariableResolver().resolveVariable(faces, property.toString()); } else { if (base instanceof List || base.getClass().isArray()) { return this.getPropertyResolver().getValue(base, Integer.parseInt(property.toString())); } else { return this.getPropertyResolver().getValue(base, property); } } } catch (PropertyNotFoundException e) { throw new javax.el.PropertyNotFoundException(e.getMessage(), e .getCause()); } catch (EvaluationException e) { throw new ELException(e.getMessage(), e.getCause()); } }