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

com.avaje.ebeaninternal.server.persist.DmlUtil Maven / Gradle / Ivy

There is a newer version: 8.1.1
Show newest version
package com.avaje.ebeaninternal.server.persist;


/**
 * Utility object with helper methods for DML.
 */
public class DmlUtil {

  /**
   * Return true if the value is null or a Numeric 0 (for primitive int's and long's) or Option empty.
   */
  public static boolean isNullOrZero(Object value) {
    return value == null || value instanceof Number && ((Number) value).longValue() == 0l;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy