public static void notNull(String varname, Object var) { if (var == null) { throw new NullPointerException( MessageUtils.getExceptionMessageString( MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, varname)); } }
/** * method for adding a message regarding missing ancestor to context * * @param ctx * @param clientId */ private static void addOmittedMessage(FacesContext jsf, String clientId, String key) { Object[] params = new Object[] {}; FacesMessage m = MessageUtils.getExceptionMessage(key, params); m.setSeverity(FacesMessage.SEVERITY_WARN); jsf.addMessage(clientId, m); }
/** * method for adding a message regarding missing ancestor to context * * @param ctx * @param clientId */ private static void addOmittedMessage(FacesContext jsf, String clientId, String key) { Object[] params = new Object[] {}; FacesMessage m = MessageUtils.getExceptionMessage(key, params); m.setSeverity(FacesMessage.SEVERITY_WARN); jsf.addMessage(clientId, m); }
public static void notNullViewId(String viewId) { if (viewId == null) { throw new IllegalArgumentException( getExceptionMessageString( NULL_VIEW_ID_ERROR_MESSAGE_ID)); } }
/** * method for adding a message regarding missing ancestor to context * * @param ctx * @param clientId */ private static void addOmittedMessage(FacesContext jsf, String clientId, String key) { Object[] params = new Object[] {}; FacesMessage m = MessageUtils.getExceptionMessage(key, params); m.setSeverity(FacesMessage.SEVERITY_WARN); jsf.addMessage(clientId, m); }
private static void checkNotNull(FacesCompositeELResolver composite, ApplicationAssociate associate) { if (associate == null) { throw new NullPointerException( getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "associate")); } if (composite == null) { throw new NullPointerException( getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "composite")); } }
public Object getAsObject(FacesContext context, UIComponent component, String value) { Converter delegate = getDelegate(context); if (delegate != null) { return delegate.getAsObject(context, component, value); } else { throw new ConverterException( MessageUtils.getExceptionMessage( MessageUtils.CANNOT_CONVERT_ID, converterId != null ? converterId.getExpressionString() : "", binding != null ? binding.getExpressionString() : "")); } }
public static void notNull(String varname, Object var) { if (var == null) { throw new NullPointerException( getExceptionMessageString( NULL_PARAMETERS_ERROR_MESSAGE_ID, varname)); } }
public String getAsString(FacesContext context, UIComponent component, Object value) { Converter delegate = getDelegate(context); if (delegate != null) { return delegate.getAsString(context, component, value); } else { throw new ConverterException( MessageUtils.getExceptionMessage( MessageUtils.CANNOT_CONVERT_ID, converterId != null ? converterId.getExpressionString() : "", binding != null ? binding.getExpressionString() : "")); } }
public static void notNullViewId(String viewId) { if (viewId == null) { throw new IllegalArgumentException( getExceptionMessageString( NULL_VIEW_ID_ERROR_MESSAGE_ID)); } }
public Object getAsObject(FacesContext context, UIComponent component, String value) { Converter delegate = getDelegate(context); if (delegate != null) { return delegate.getAsObject(context, component, value); } else { throw new ConverterException( MessageUtils.getExceptionMessage( MessageUtils.CANNOT_CONVERT_ID, converterId != null ? converterId.getExpressionString() : "", binding != null ? binding.getExpressionString() : "")); } }
public static void notNull(String varname, Object var) { if (var == null) { throw new NullPointerException( getExceptionMessageString( NULL_PARAMETERS_ERROR_MESSAGE_ID, varname)); } }
public String getAsString(FacesContext context, UIComponent component, Object value) { Converter delegate = getDelegate(context); if (delegate != null) { return delegate.getAsString(context, component, value); } else { throw new ConverterException( MessageUtils.getExceptionMessage( MessageUtils.CANNOT_CONVERT_ID, converterId != null ? converterId.getExpressionString() : "", binding != null ? binding.getExpressionString() : "")); } }
public static void notNullViewId(String viewId) { if (viewId == null) { throw new IllegalArgumentException( getExceptionMessageString( NULL_VIEW_ID_ERROR_MESSAGE_ID)); } }
@Override public Object getAsObject(FacesContext context, UIComponent component, String value) { Converter delegate = getDelegate(context); if (delegate != null) { return delegate.getAsObject(context, component, value); } else { throw new ConverterException( MessageUtils.getExceptionMessage( MessageUtils.CANNOT_CONVERT_ID, converterId != null ? converterId.getExpressionString() : "", binding != null ? binding.getExpressionString() : "")); } }
public static void notNull(String varname, Object var) { if (var == null) { throw new NullPointerException( MessageUtils.getExceptionMessageString( MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, varname)); } }
private static void checkNotNull(FacesCompositeELResolver composite, ApplicationAssociate associate) { if (associate == null) { throw new NullPointerException(getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "associate")); } if (composite == null) { throw new NullPointerException(getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "composite")); } }
private static void checkNotNull(FacesCompositeELResolver composite, ApplicationAssociate associate) { if (associate == null) { throw new NullPointerException( getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "associate")); } if (composite == null) { throw new NullPointerException( getExceptionMessageString(NULL_PARAMETERS_ERROR_MESSAGE_ID, "composite")); } }
protected void validateParameters(FacesContext context, UIComponent component) { if (context == null) { throw new NullPointerException(MessageUtils.getExceptionMessageString( MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, "context")); } if (component == null) { throw new NullPointerException(MessageUtils.getExceptionMessageString( MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, "component")); } }
/** * @see ExternalContext#encodeResourceURL(String) */ public String encodeResourceURL(String url) { if (null == url) { String message = MessageUtils.getExceptionMessageString (MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, "url"); throw new NullPointerException(message); } return ((HttpServletResponse) response).encodeURL(url); }