Here you can find the source of getBoolean(Properties props, String key)
public static boolean getBoolean(Properties props, String key)
//package com.java2s; //License from project: Apache License import java.util.*; public class Main { public static boolean getBoolean(Properties props, String key) { return getBoolean(props, key, false); }/*from w w w . j a v a2s.co m*/ public static boolean getBoolean(Properties props, String key, boolean defalutValue) { boolean value = defalutValue; if (props.containsKey(key)) { String vauleStr = props.getProperty(key).trim(); if (vauleStr.equals("true") || vauleStr.equals("false")) { value = Boolean.parseBoolean(vauleStr); } } return value; } }