YARN-6118. Add javadoc for Resources.isNone. Contributed by Andres Perez.
(cherry picked from commit 3a0a0a485a
)
This commit is contained in:
parent
e259a818ad
commit
7b2b6caf12
|
@ -144,6 +144,12 @@ public class Resources {
|
||||||
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…
Reference in New Issue