1/* 2 * Copyright (c) 2007 Mockito contributors 3 * This program is made available under the terms of the MIT License. 4 */ 5 6package org.mockito.internal.matchers; 7 8import org.mockito.ArgumentMatcher; 9 10import java.io.Serializable; 11 12public class NotNull implements ArgumentMatcher<Object>, Serializable { 13 14 public static final NotNull NOT_NULL = new NotNull(); 15 16 private NotNull() { 17 } 18 19 public boolean matches(Object actual) { 20 return actual != null; 21 } 22 23 public String toString() { 24 return "notNull()"; 25 } 26} 27