Here you can find the source of convertBoolean(String value)
private static Boolean convertBoolean(String value)
//package com.java2s; //License from project: Apache License public class Main { private static Boolean convertBoolean(String value) { if (value == null || "".equals(value.trim())) { return null; } else if ("true".equalsIgnoreCase(value)) { return true; } else if ("false".equalsIgnoreCase(value)) { return false; } else if ("yes".equalsIgnoreCase(value)) { return true; } else if ("no".equalsIgnoreCase(value)) { return false; } else if ("show".equalsIgnoreCase(value)) { return true; } else if ("hide".equalsIgnoreCase(value)) { return false; } else if ("on".equalsIgnoreCase(value)) { return true; } else if ("off".equalsIgnoreCase(value)) { return false; } else if ("y".equalsIgnoreCase(value)) { return true; } else if ("n".equalsIgnoreCase(value)) { return false; }/*from www . j a v a 2 s .c o m*/ return null; } }