YARN-6118. Add javadoc for Resources.isNone. Contributed by Andres Perez.
(cherry picked from commit 3a0a0a485a4145e3bd2e5946731ee1d901b51ead)
This commit is contained in:
parent
e259a818ad
commit
7b2b6caf12
@ -144,6 +144,12 @@ public static Resource none() {
|
|||||||
return NONE;
|
return NONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check whether a resource object is empty (0 memory and 0 virtual cores).
|
||||||
|
* @param other The resource to check
|
||||||
|
* @return {@code true} if {@code other} has 0 memory and 0 virtual cores,
|
||||||
|
* {@code false} otherwise
|
||||||
|
*/
|
||||||
public static boolean isNone(Resource other) {
|
public static boolean isNone(Resource other) {
|
||||||
return NONE.equals(other);
|
return NONE.equals(other);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user