src/Incoming/Hydrator/Exception/InvalidDelegateException.php
public static function forNonCallable(
        string $name = null,
        int $code = self::CODE_FOR_NON_CALLABLE,
        Throwable $previous = null
    ): self {
        $message = self::DEFAULT_MESSAGE;

        if (null !== $name) {
            $message .= sprintf(
                self::MESSAGE_EXTENSION_NAME_FORMAT,
                $name
            );
        }

        $message .= self::MESSAGE_EXTENSION_FOR_NON_CALLABLE;

        return new static($message, $code, $previous);
    }
public static function forNonCallable(
        string $name = null,
        int $code = self::CODE_FOR_NON_CALLABLE,
        Throwable $previous = null
    ): self {
        $message = self::DEFAULT_MESSAGE;

        if (null !== $name) {
            $message .= sprintf(
                self::MESSAGE_EXTENSION_NAME_FORMAT,
                $name
            );
        }

        $message .= self::MESSAGE_EXTENSION_FOR_NON_CALLABLE;

        return new static($message, $code, $previous);
    }
public static function forNonCallable ( string $ name = null , int $ code = self :: CODE_FOR_NON_CALLABLE , Throwable $ previous = null ) : self { $ message = self :: DEFAULT_MESSAGE ; if ( null !== $ name ) { $ message .= sprintf ( self :: MESSAGE_EXTENSION_NAME_FORMAT , $ name ) ; } $ message .= self :: MESSAGE_EXTENSION_FOR_NON_CALLABLE ; return new static ( $ message , $ code , $ previous ) ; }
Create an exception instance for a delegate that isn't callable.

@param string|null $name The name of the delegate.
@param int $code The exception code.
@param Throwable|null $previous A previous exception used for chaining.
@return static The newly created exception.
Create an exception instance for a delegate that isn t callable .