This method returns the value it is passed, or null if the value
matches the nullValue argument.

@param value value under test
@param nullValue return null if value under test matches this value
@return value or null
420686
private Integer getNullOnValue(Integer value, int nullValue)
   {
      return (NumberHelper.getInt(value) == nullValue ? null : value);
   }
1336698
public static String getNullAsValue(String input, String value) {
    return (input == null) ? value : input;
  }
1345755
public static void checkNull(Object o, Object value) {
        if (o != null)
            error(String.valueOf(value));
    }
746340
public static void checkNotNull(Object value, String message, Object... args) {
    if (value == null) {
      throw new NullPointerException(String.format(message, args));
    }
  }
774998
public static String safeToString(Object value) {
    try {
      // TODO(b/36844237): Re-evaluate if this is the best place for null handling (null is also
      // handled for arguments via visitNull() and this is only for literal arguments).
      return value != null ? toString(value) : "null";
    } catch (RuntimeException e) {
      return getErrorString(value, e);
    }
  }
1067621
public static String checkNull(String value, String elseValue) {
        return isNull(value) ? elseValue : value;
    }
1213343
protected boolean valueIsNull(MapEntryValue value) {
    return value == null || value.type() == MapEntryValue.Type.TOMBSTONE;
  }
95786
@NotNull
    public static OptionalBoolean ofNullable(@Nullable Boolean value) {
        return value == null ? EMPTY : of(value);
    }
69752
@Nullable
    public T getValue() {
        Object data = mData;
        if (data != NOT_SET) {
            //noinspection unchecked
            return (T) data;
        }
        return null;
    }
1104279
public static Integer toInteger(final StringValue stringValue)
	{
		Integer value = null;
		if (isNotNullOrEmpty(stringValue))
		{
			try
			{
				value = stringValue.toInteger();
			}
			catch (final StringValueConversionException e)
			{
				LOGGER.error("Error by converting the given StringValue.", e);
			}
		}
		return value;
	}
656141
public Integer getDefaultOnNull(Integer value, Integer defaultValue)
   {
      return (value == null ? defaultValue : value);
   }
311598
public Object getValue(String k) {
	if (values == null) {
	    return null;
	} else {
	    return values.get(k);
	}
    }
81595
public static Integer getAsInteger(Object value) {
		Integer result = null;

		try {
			if (value instanceof String) {
				result = Integer.valueOf((String) value);
			} else if (value instanceof Number) {
				result = ((Number) value).intValue();
			} else {
				result = null;
			}
		} catch (Exception e) {
			result = null;
		}

		return result == null ? 0 : result;
	}
208915
public void setNullValue(String nullValue) {
        this.nullValue = nullValue;
        this.nullValueChars = nullValue.toCharArray();
        this.nullValueBytes = toBytes(nullValue, nullValue);
    }
1143286
public Double getDefaultOnNull(Double value, Double defaultValue)
   {
      return (value == null ? defaultValue : value);
   }
40630
private boolean equalsNull(String value1, String value2) {
        return (value1 == value2 || value1 == null || (value1 != null && value1.equalsIgnoreCase(value2)));
    }
313460
public static void checkNull(Object value, String message, Object... args) {
    if (value != null) {
      throw new IllegalArgumentException(String.format(message, args));
    }
  }