Example usage for org.apache.commons.lang BooleanUtils toBooleanObject

List of usage examples for org.apache.commons.lang BooleanUtils toBooleanObject

Introduction

In this page you can find the example usage for org.apache.commons.lang BooleanUtils toBooleanObject.

Prototype

public static Boolean toBooleanObject(String str) 

Source Link

Document

Converts a String to a Boolean.

'true', 'on' or 'yes' (case insensitive) will return true.

Usage

From source file:stc.app.bean.lang.ToStringBuilder.java

/**
 * <p>//from  ww w. j av  a  2  s  .c  o  m
 * Append to the <code>toString</code> a <code>long</code> array.
 * </p>
 * 
 * <p>
 * A boolean parameter controls the level of detail to show. Setting <code>true</code> will output
 * the array in full. Setting <code>false</code> will output a summary, typically the size of the
 * array.
 * </p>
 * 
 * @param fieldName the field name
 * @param array the array to add to the <code>toString</code>
 * @param fullDetail <code>true</code> for detail, <code>false</code> for summary info
 * @return this
 */
public ToStringBuilder append(String fieldName, long[] array, boolean fullDetail) {
    style.append(buffer, fieldName, array, BooleanUtils.toBooleanObject(fullDetail));
    return this;
}

From source file:stc.app.bean.lang.ToStringBuilder.java

/**
 * <p>/*ww w .j  a  v a  2s  .  c  om*/
 * Append to the <code>toString</code> an <code>Object</code> value.
 * </p>
 * 
 * @param fieldName the field name
 * @param obj the value to add to the <code>toString</code>
 * @param fullDetail <code>true</code> for detail, <code>false</code> for summary info
 * @return this
 */
public ToStringBuilder append(String fieldName, Object obj, boolean fullDetail) {
    style.append(buffer, fieldName, obj, BooleanUtils.toBooleanObject(fullDetail));
    return this;
}

From source file:stc.app.bean.lang.ToStringBuilder.java

/**
 * <p>/*from   w w  w . j ava  2  s.com*/
 * Append to the <code>toString</code> an <code>Object</code> array.
 * </p>
 * 
 * <p>
 * A boolean parameter controls the level of detail to show. Setting <code>true</code> will output
 * the array in full. Setting <code>false</code> will output a summary, typically the size of the
 * array.
 * </p>
 * 
 * @param fieldName the field name
 * @param array the array to add to the <code>toString</code>
 * @param fullDetail <code>true</code> for detail, <code>false</code> for summary info
 * @return this
 */
public ToStringBuilder append(String fieldName, Object[] array, boolean fullDetail) {
    style.append(buffer, fieldName, array, BooleanUtils.toBooleanObject(fullDetail));
    return this;
}

From source file:stc.app.bean.lang.ToStringBuilder.java

/**
 * <p>// w  w w.j a  v  a  2  s  . c om
 * Append to the <code>toString</code> a <code>short</code> array.
 * </p>
 * 
 * <p>
 * A boolean parameter controls the level of detail to show. Setting <code>true</code> will output
 * the array in full. Setting <code>false</code> will output a summary, typically the size of the
 * array.
 * 
 * @param fieldName the field name
 * @param array the array to add to the <code>toString</code>
 * @param fullDetail <code>true</code> for detail, <code>false</code> for summary info
 * @return this
 */
public ToStringBuilder append(String fieldName, short[] array, boolean fullDetail) {
    style.append(buffer, fieldName, array, BooleanUtils.toBooleanObject(fullDetail));
    return this;
}