|
|||||||||||||||||||
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover | |||||||||||||||||||
Source file | Conditionals | Statements | Methods | TOTAL | |||||||||||||||
IsNull.java | - | 50% | 66.7% | 60% |
|
1 |
/* Copyright (c) 2000-2003, jMock.org. See bundled LICENSE.txt */
|
|
2 |
package org.jmock.constraint;
|
|
3 |
|
|
4 |
import org.jmock.Constraint;
|
|
5 |
|
|
6 |
/**
|
|
7 |
* Is the value null?
|
|
8 |
*/
|
|
9 |
public class IsNull implements Constraint { |
|
10 | 14 |
public IsNull() {
|
11 |
} |
|
12 |
|
|
13 | 4 |
public boolean eval(Object o) { |
14 | 4 |
return o == null; |
15 |
} |
|
16 |
|
|
17 | 0 |
public String toString() {
|
18 | 0 |
return "null"; |
19 |
} |
|
20 |
} |
|
21 |
|
|
22 |
|
|