Java Primitive Type Create toPrimitive(final Boolean b)

Here you can find the source of toPrimitive(final Boolean b)

Description

to Primitive

License

Open Source License

Parameter

Parameter Description
b the Boolean wrapper

Return

false if b is null of false, true otherwise

Declaration

public static boolean toPrimitive(final Boolean b) 

Method Source Code

//package com.java2s;

public class Main {
    /**/* www .j  ava  2s  .c  o m*/
     * @param b the Boolean wrapper
     * @return false if b is null of false, true otherwise
     */
    public static boolean toPrimitive(final Boolean b) {
        return b == null ? false : b.booleanValue();
    }
}

Related

  1. toPrimitive(Class clazz)
  2. toPrimitive(Double[] array)
  3. toPrimitive(Double[] array)
  4. toPrimitive(Double[] doubles)
  5. toPrimitive(Double[] vals)
  6. toPrimitive(final Character value, final char defaultValue)
  7. toPrimitive(final Double[] arr)
  8. toPrimitive(Float[] floats)
  9. toPrimitive(Integer[] array)