Java Object to Boolean objectToBoolean(Object o)

Here you can find the source of objectToBoolean(Object o)

Description

object To Boolean

License

Apache License

Declaration

public static final boolean objectToBoolean(Object o) 

Method Source Code

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

public class Main {
    public static final boolean objectToBoolean(Object o) {
        return o != null ? Boolean.valueOf(o.toString()).booleanValue() : false;
    }/*  ww w.  jav  a2s  .c o m*/
}

Related

  1. castBoolean(Object o, boolean defaultValue)
  2. castBoolean(Object obj)
  3. castToBoolean(Object value)
  4. castToBoolean(Object value)
  5. castToBoolean(String fieldValue)
  6. objectToBoolean(Object o)
  7. objectToBoolean(Object Obj)
  8. objectToBoolean(Object p1)
  9. toBoolean(Object object)