Java String Indent Format indent(int indentLevel)

Here you can find the source of indent(int indentLevel)

Description

indent

License

Apache License

Declaration

public static String indent(int indentLevel) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static String indent(int indentLevel) {
        StringBuilder buffer = new StringBuilder();
        for (int i = 0; i < indentLevel; i++) {
            buffer.append("  ");
        }//  w  w  w  .  ja v  a 2 s.c o  m
        return buffer.toString();
    }
}

Related

  1. indent(int indent)
  2. indent(int indent)
  3. indent(int indent)
  4. indent(int indent, int tab, String string)
  5. indent(int indent, StringBuffer sb)
  6. indent(int level)
  7. indent(int level)
  8. indent(int level)
  9. indent(int level)