Java String Pad Right tailPad(String target, String padChar, int length)

Here you can find the source of tailPad(String target, String padChar, int length)

Description

tail Pad

License

Apache License

Declaration

public static String tailPad(String target, String padChar, int length) 

Method Source Code

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

public class Main {
    public static String tailPad(String target, String padChar, int length) {
        if (length == 0 || target.length() >= length) {
            return target;
        }/*from   www.j  ava  2  s  .  c om*/
        return tailPad(target + padChar, padChar, length);
    }
}

Related

  1. rightPaddWithSpace(String pString_, int stellen)
  2. rightPadInt(int number, int width)
  3. rightPadOrTruncate(String str, int resultSz)
  4. rightPadString(String str, char pad, int length)
  5. rightPadString(StringBuilder builder, char padding, int multipleOf)