Java String Trim Left ltrim(String list, char[] del)

Here you can find the source of ltrim(String list, char[] del)

Description

ltrim

License

LGPL

Declaration

private static String ltrim(String list, char[] del) 

Method Source Code

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

public class Main {
    private static String ltrim(String list, char[] del) {
        int len = list.length();
        char c;//from ww  w. j  a v  a  2  s  . c o  m
        //       remove at start
        outer: while (len > 0) {
            c = list.charAt(0);
            for (int i = 0; i < del.length; i++) {
                if (c == del[i]) {
                    list = list.substring(1);
                    len = list.length();
                    continue outer;
                }
            }
            break;
        }
        return list;
    }
}

Related

  1. ltrim(CharSequence str)
  2. ltrim(final String str)
  3. ltrim(final String str, final char filler)
  4. ltrim(final String text)
  5. lTrim(final String value)
  6. ltrim(String orig)
  7. ltrim(String pString)
  8. ltrim(String s)
  9. ltrim(String s)