Class AssertInstanceOf


  • class AssertInstanceOf
    extends java.lang.Object
    AssertInstanceOf is a collection of utility methods that support asserting that an object is of an expected type — in other words, if it can be assigned to the expected type.
    Since:
    5.8
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private AssertInstanceOf()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      (package private) static <T> T assertInstanceOf​(java.lang.Class<T> expectedType, java.lang.Object actualValue)  
      private static <T> T assertInstanceOf​(java.lang.Class<T> expectedType, java.lang.Object actualValue, java.lang.Object messageOrSupplier)  
      (package private) static <T> T assertInstanceOf​(java.lang.Class<T> expectedType, java.lang.Object actualValue, java.lang.String message)  
      (package private) static <T> T assertInstanceOf​(java.lang.Class<T> expectedType, java.lang.Object actualValue, java.util.function.Supplier<java.lang.String> messageSupplier)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AssertInstanceOf

        private AssertInstanceOf()
    • Method Detail

      • assertInstanceOf

        static <T> T assertInstanceOf​(java.lang.Class<T> expectedType,
                                      java.lang.Object actualValue)
      • assertInstanceOf

        static <T> T assertInstanceOf​(java.lang.Class<T> expectedType,
                                      java.lang.Object actualValue,
                                      java.lang.String message)
      • assertInstanceOf

        static <T> T assertInstanceOf​(java.lang.Class<T> expectedType,
                                      java.lang.Object actualValue,
                                      java.util.function.Supplier<java.lang.String> messageSupplier)
      • assertInstanceOf

        private static <T> T assertInstanceOf​(java.lang.Class<T> expectedType,
                                              java.lang.Object actualValue,
                                              java.lang.Object messageOrSupplier)