/** * Records that the message being built has a variable argument, whose display value is also * {@link MessageSourceResolvable}. Adds the arg to the args list. Successive calls to this method add additional * resolvable args. Args are applied in the order they are added. * @param arg the resolvable message argument * @return this, for fluent API usage */ public MessageBuilder resolvableArg(Object arg) { args.add(new ResolvableArgument(arg)); return this; }
/** * Records that the message being built has variable arguments, whose display values are also * {@link MessageSourceResolvable} instances. Adds the args to the args list. Successive calls to this method add * additional resolvable args. Args are applied in the order they are added. * @param args the resolvable message arguments * @return this, for fluent API usage */ public MessageBuilder resolvableArgs(Object[] args) { if (args == null) { return this; } for (int i = 0; i < args.length; i++) { this.args.add(new ResolvableArgument(args[i])); } return this; }
/** * Records that the message being built has variable arguments, whose display values are also * {@link MessageSourceResolvable} instances. Adds the args to the args list. Successive calls to this method add * additional resolvable args. Args are applied in the order they are added. * @param args the resolvable message arguments * @return this, for fluent API usage */ public MessageBuilder resolvableArgs(Object... args) { if (args == null) { return this; } for (Object arg : args) { this.args.add(new ResolvableArgument(arg)); } return this; }
/** * Records that the message being built has variable arguments, whose display values are also * {@link MessageSourceResolvable} instances. Adds the args to the args list. Successive calls to this method add * additional resolvable args. Args are applied in the order they are added. * @param args the resolvable message arguments * @return this, for fluent API usage */ public MessageBuilder resolvableArgs(Object... args) { if (args == null) { return this; } for (Object arg : args) { this.args.add(new ResolvableArgument(arg)); } return this; }
/** * Records that the message being built has a variable argument, whose display value is also * {@link MessageSourceResolvable}. Adds the arg to the args list. Successive calls to this method add additional * resolvable args. Args are applied in the order they are added. * @param arg the resolvable message argument * @return this, for fluent API usage */ public MessageBuilder resolvableArg(Object arg) { args.add(new ResolvableArgument(arg)); return this; }
/** * Records that the message being built has a variable argument, whose display value is also * {@link MessageSourceResolvable}. Adds the arg to the args list. Successive calls to this method add additional * resolvable args. Args are applied in the order they are added. * @param arg the resolvable message argument * @return this, for fluent API usage */ public MessageBuilder resolvableArg(Object arg) { args.add(new ResolvableArgument(arg)); return this; }