Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.jruby.util.log;
 
 
 
 
     private PrintStream stream;
        this. = stream;
    }
    public void write(String messageObject... args) {
        final StringBuilder builder = new StringBuilder();
        if (message != null) {
            final String[] strings = message.split("\\{\\}");
            if (args.length == 0 || strings.length == args.length) {
                for (int i = 0; i < strings.lengthi++) {
                    builder.append(strings[i]);
                    if (args.length > 0) {
                        builder.append(args[i]);
                    }
                }
            } else if (strings.length == 0 && args.length == 1) {
                builder.append(args[0]);
            } else {
                .println("wrong number of placeholders / arguments");
            }
        }
        .println(builder.toString());
    }
    public PrintStream getStream() {
        return ;
    }
New to GrepCode? Check out our FAQ X