/** * Convenience method that may be used to generate and throw an Exception for an attempt to assign a null value to a property that * requires non-null values. * * @param propertyName The name of the property being incorrectly assigned. */ protected void blockNullAssignment(String propertyName) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(NULL_COMPONENT_PROPERTY, new Object[]{propertyName}); throw ce; }
/** * Convenience method that may be used to generate and throw an Exception for an attempt to set the specified property if the * component is started. * * @param propertyName The name of the property being incorrectly assigned; included in the Exception message. */ protected void blockAssignmentWhileStarted(String propertyName) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(PROPERTY_CHANGE_AFTER_STARTUP, new Object[]{propertyName}); throw ce; }
/** * Convenience method that may be used to generate and throw an Exception for an attempt to assign a null value to a property that * requires non-null values. * * @param propertyName The name of the property being incorrectly assigned. */ protected void blockNullAssignment(String propertyName) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(NULL_COMPONENT_PROPERTY, new Object[]{propertyName}); throw ce; }
protected void blockNegative(int n, String name) { if (n < 0) { ConfigurationException ex = new ConfigurationException(); // Invalid {0} for destination ''{1}''. {0} cannot be negative. ex.setMessage(ERR_MSG_INVALID_NEGATIVE_VALUE, new Object[]{name, destinationName}); throw ex; } } }
/** * Convenience method that may be used to generate and throw an Exception for an attempt to assign a null value to a property that * requires non-null values. * * @param propertyName The name of the property being incorrectly assigned. */ protected void blockNullAssignment(String propertyName) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(NULL_COMPONENT_PROPERTY, new Object[]{propertyName}); throw ce; }
/** * Convenience method that may be used to generate and throw an Exception for an attempt to set the specified property if the * component is started. * * @param propertyName The name of the property being incorrectly assigned; included in the Exception message. */ protected void blockAssignmentWhileStarted(String propertyName) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(PROPERTY_CHANGE_AFTER_STARTUP, new Object[]{propertyName}); throw ce; }
protected void blockNegative(int n, String name) { if (n < 0) { ConfigurationException ex = new ConfigurationException(); // Invalid {0} for destination ''{1}''. {0} cannot be negative. ex.setMessage(ERR_MSG_INVALID_NEGATIVE_VALUE, new Object[]{name, destinationName}); throw ex; } } }
protected void validateEndpointProtocol() { if (isSecure() && !url.startsWith("https:")) { ConfigurationException ce = new ConfigurationException(); ce.setMessage(11100, new Object[] {url, "https"}); throw ce; } } }
private ConfigurationException wrapException (XPathExpressionException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; }
private ConfigurationException wrapException(XPathExpressionException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; }
private ConfigurationException wrapException (XPathExpressionException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; }
private ConfigurationException wrapException(XPathException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(XPathExpressionException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(XPathExpressionException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; } }
private ConfigurationException wrapException(TransformerException exception) { ConfigurationException result = new ConfigurationException(); result.setDetails(PARSER_INTERNAL_ERROR); result.setRootCause(exception); return result; }