Class OpUtils


  • public final class OpUtils
    extends java.lang.Object
    Utility class that OpN classes use for reporting certain failure patterns.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <T> T unsupported​(java.lang.String op, java.lang.Object... a)
      This method builds a meaningful exception and throws it immediately.
      • Methods inherited from class java.lang.Object

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

      • unsupported

        public static <T> T unsupported​(java.lang.String op,
                                        java.lang.Object... a)
        This method builds a meaningful exception and throws it immediately.
        Type Parameters:
        T - Return type. This function never returns, this type is a placeholder that allows you to write stuff like "return unsupported(op, args)".
        Parameters:
        op - The name of the operation
        a - The arguments that have been passed, and that made the operation fail.
        Returns:
        Nothing, since it throws an exception
        Throws:
        java.lang.UnsupportedOperationException - ALWAYS