Package org.agrona
Class Verify
java.lang.Object
org.agrona.Verify
Various verification checks to be applied in code.
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidVerify that a reference is not null.static voidVerify that a map contains an entry for a given key.static voidverifyNull(Object ref, String name) Verify that a reference is null.
-
Method Details
-
notNull
Verify that a reference is not null.- Parameters:
ref- to be verified not null.name- of the reference to be verified.
-
verifyNull
Verify that a reference is null.- Parameters:
ref- to be verified as null.name- of the reference to be verified.
-
present
Verify that a map contains an entry for a given key.- Parameters:
map- to be checked.key- to get by.name- of entry.- Throws:
NullPointerException- if map or key is nullIllegalStateException- if the entry does not exist.
-