All Downloads are FREE. Search and download functionalities are using the official Maven repository.

javadoc.com.google.common.base.Defaults.html Maven / Gradle / Ivy

The newest version!







Defaults (Guava: Google Core Libraries for Java 11.0.1 API)














com.google.common.base
Class Defaults

java.lang.Object
  extended by com.google.common.base.Defaults

public final class Defaults
extends Object

This class provides default values for all Java types, as defined by the JLS.

Author:
Ben Yu

Method Summary
static
<T> T
defaultValue(Class<T> type)
          Returns the default value of type as defined by JLS --- 0 for numbers, false for boolean and '\0' for char.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

defaultValue

public static <T> T defaultValue(Class<T> type)
Returns the default value of type as defined by JLS --- 0 for numbers, false for boolean and '\0' for char. For non-primitive types and void, null is returned.



Copyright © 2010-2012. All Rights Reserved.




© 2015 - 2025 Weber Informatics LLC | Privacy Policy