Get callable handler.

@return  callable  The validate callback.

@since   2.0
762969
public function getHandler()
    {
        if (is_callable($this->handler)) {
            return $this->handler;
        }

        $options = $this->options;

        return function ($value) use ($options) {
            if (in_array($value, $options)) {
                return true;
            }

            return false;
        };
    }
362739
public function get_callback_reflection() {
		if ( is_array( $this->callback ) ) {
			return new \ReflectionMethod( $this->callback[0], $this->callback[1] );
		} else {
			return new \ReflectionFunction( $this->callback );
		}
	}
1178487
function onFailure(/*callable*/$callable)
    {
        if ($callable === false)
        {
            // Disable On Failure Handler
            //
            $this->_onFailure = $callable;
            return $this;
        }


        if (! is_callable($callable) )
            throw new \Exception(sprintf(
                'The argument given is not callable; given: (%s).'
                , \Poirot\Std\flatten($callable)
            ));


        ## bind it into latest bind object
        #
        // DO_LEAST_PHPVER_SUPPORT 5.4 closure bindto
        if ($callable instanceof \Closure && version_compare(phpversion(), '5.4.0') > 0) {
            $callable = \Closure::bind(
                $callable
                , $this
                , get_class($this)
            );
        }

        $this->_onFailure = $callable;
        return $this;
    }
165605
public function getHandlerStack(): HandlerStack
    {
        if ($this->handlerStack) {
            return $this->handlerStack;
        }

        $this->handlerStack = HandlerStack::create($this->getGuzzleHandler());

        foreach ($this->middlewares as $name => $middleware) {
            $this->handlerStack->push($middleware, $name);
        }

        return $this->handlerStack;
    }
697438
public function getHandlers()
    {
        $handlers = [];
        foreach ($this->data['handlers'] as $handler => $count) {
            list($class, $method) = explode('::', $handler);
            unset($class);
            $handlers[$method] = $method . '(' . $count . ')';
        }

        return $handlers;
    }
670051
public function getHandler() {
        $rs = $this->runQuery(
            "SELECT handler FROM " . self::$jobsTable . " WHERE id = ?",
            array($this->job_id)
        );
        foreach ($rs as $r) return unserialize($r["handler"]);
        return false;
    }
634325
public function get_handler()
    {
        $handler = new PrettyPageHandler();
            
        $handler->addDataTableCallback('$wp_query', [$this, 'add_query']);

        $handler->addDataTableCallback('$post', [$this, 'add_post']);

        $handler->addDataTableCallback('$wp', [$this, 'add_wp']);

        return $handler;
    }
634020
public function getVerifyHandler()
    {
        if (is_callable($this->verifyHandler)) {
            return $this->verifyHandler;
        }

        return function ($password, $hash) {
            return password_verify($password, $hash);
        };
    }
161819
public function isCallable() : bool 
    {
        return is_callable(
            [
                $this->namespace . $this->getController(true),
                $this->getAction(true)
            ]
        );
    }
1036659
public function getHandle()
    {
        if(!$handle = $this->getProperty($this->getIdentityKey())) {
            $handle = parent::getHandle();
        }

        return $handle;
    }
1252543
public function getHandle()
    {
        $result = false;
        if($entity = $this->getIterator()->current()) {
            $result = $entity->getHandle();
        }

        return $result;
    }
477150
protected function runCallable()
    {
        $callable = $this->action['uses'];

        return $callable(...array_values($this->resolveMethodDependencies(
            $this->parametersWithoutNulls(), new ReflectionFunction($this->action['uses'])
        )));
    }
180249
protected function getLoggerCallable()
    {
        if (!is_callable($this->loggerCallable)) {
            $loggerCallable = $this->getOption('logger_callable');

            if (is_callable($loggerCallable)) {
                $this->loggerCallable = $loggerCallable;
            }
        }

        return $this->loggerCallable;
    }
498467
public function getHandler(string $handler): Handler
    {
        if (!isset($this->handlers[$handler])) {
            if (!class_exists($handler) || !class_implements($handler, Handler::class)) {
                throw new \RuntimeException("No handler found for '$handler'.");
            }

            $instance = new $handler();
            $this->handlers[$handler] = $instance;
        } else {
            $instance = $this->handlers[$handler];
        }

        return $instance;
    }
1118107
public function isCallable()
    {
        if ($this->isCallable === null) {
            $this->isCallable = is_callable($this->native, false);
        }
        return $this->isCallable;
    }
1181182
static public function getCaller()
    {
        $backtrace = debug_backtrace();
        array_shift($backtrace);
        $current = array_shift($backtrace);
        $caller = isset($backtrace[0]) ? $backtrace[0] : $current;
        if (!isset($caller['class']))  $caller['class'] = null;
        if (!isset($caller['object'])) $caller['object'] = null;
        return $caller;
    }
281754
public function getHandle()
    {
        if(!$handle = $this->getProperty($this->getIdentityColumn())) {
            $handle = parent::getHandle();
        }

        return $handle;
    }