Here you can find the source of assertNotNull(final Object object, final String message)
Parameter | Description |
---|---|
object | the object to check. |
message | the message to display if the object is null. |
public static void assertNotNull(final Object object, final String message)
//package com.java2s; /*//from w w w . ja v a 2s. c o m * oxCore is available under the MIT License (2008). See http://opensource.org/licenses/MIT for full text. * * Copyright (c) 2014, Gluu */ public class Main { /** * Check whether the object is null or not. If it is, throw an exception and display the message. * * @param object the object to check. * @param message the message to display if the object is null. */ public static void assertNotNull(final Object object, final String message) { if (object == null) { throw new IllegalArgumentException(message); } } }