/** * Creates a parameterized message. * @param messagePattern The message "format" string. This will be a String containing "{}" placeholders * where parameters should be substituted. * @param arguments The arguments for substitution. * @param throwable A Throwable. */ public ParameterizedMessage(final String messagePattern, final Object[] arguments, final Throwable throwable) { this.argArray = arguments; this.throwable = throwable; init(messagePattern); }
/** * Constructs a ParameterizedMessage which contains the arguments converted to String as well as an optional * Throwable. * * <p>If the last argument is a Throwable and is NOT used up by a placeholder in the message pattern it is returned * in {@link #getThrowable()} and won't be contained in the created String[]. * If it is used up {@link #getThrowable()} will return null even if the last argument was a Throwable!</p> * * @param messagePattern the message pattern that to be checked for placeholders. * @param arguments the argument array to be converted. */ public ParameterizedMessage(final String messagePattern, final Object... arguments) { this.argArray = arguments; init(messagePattern); }
/** * Creates a parameterized message. * @param messagePattern The message "format" string. This will be a String containing "{}" placeholders * where parameters should be substituted. * @param arguments The arguments for substitution. * @param throwable A Throwable. * @deprecated Use constructor ParameterizedMessage(String, Object[], Throwable) instead */ @Deprecated public ParameterizedMessage(final String messagePattern, final String[] arguments, final Throwable throwable) { this.argArray = arguments; this.throwable = throwable; init(messagePattern); }
/** * Creates a parameterized message. * @param messagePattern The message "format" string. This will be a String containing "{}" placeholders * where parameters should be substituted. * @param arguments The arguments for substitution. * @param throwable A Throwable. */ public ParameterizedMessage(final String messagePattern, final Object[] arguments, final Throwable throwable) { this.argArray = arguments; this.throwable = throwable; init(messagePattern); }
/** * Constructs a ParameterizedMessage which contains the arguments converted to String as well as an optional * Throwable. * * <p>If the last argument is a Throwable and is NOT used up by a placeholder in the message pattern it is returned * in {@link #getThrowable()} and won't be contained in the created String[]. * If it is used up {@link #getThrowable()} will return null even if the last argument was a Throwable!</p> * * @param messagePattern the message pattern that to be checked for placeholders. * @param arguments the argument array to be converted. */ public ParameterizedMessage(final String messagePattern, final Object... arguments) { this.argArray = arguments; init(messagePattern); }
/** * Creates a parameterized message. * @param messagePattern The message "format" string. This will be a String containing "{}" placeholders * where parameters should be substituted. * @param arguments The arguments for substitution. * @param throwable A Throwable. * @deprecated Use constructor ParameterizedMessage(String, Object[], Throwable) instead */ @Deprecated public ParameterizedMessage(final String messagePattern, final String[] arguments, final Throwable throwable) { this.argArray = arguments; this.throwable = throwable; init(messagePattern); }