src/xPDO/xPDO.php
public function call($class, $method, array $args = array(), $transient = false) {
        $return = null;
        $callback = '';
        if ($transient) {
            $className = $this->loadClass($class, '', false, true);
            if ($className) {
                $callback = array($className, $method);
            }
        } else {
            $className = $this->loadClass($class);
            if ($className) {
                $className = $this->getPlatformClass($className);
                $callback = array($className, $method);
            }
        }
        if (!empty($callback) && is_callable($callback)) {
            try {
                $return = $className::$method(...$args);
            } catch (\Exception $e) {
                $this->log(xPDO::LOG_LEVEL_ERROR, "An exception occurred calling {$className}::{$method}() - " . $e->getMessage());
            }
        } else {
            $this->log(xPDO::LOG_LEVEL_ERROR, "{$class}::{$method}() is not a valid static method.");
        }
        return $return;
    }
public function call($class, $method, array $args = array(), $transient = false) {
        $return = null;
        $callback = '';
        if ($transient) {
            $className = $this->loadClass($class, '', false, true);
            if ($className) {
                $callback = array($className, $method);
            }
        } else {
            $className = $this->loadClass($class);
            if ($className) {
                $className = $this->getPlatformClass($className);
                $callback = array($className, $method);
            }
        }
        if (!empty($callback) && is_callable($callback)) {
            try {
                $return = $className::$method(...$args);
            } catch (\Exception $e) {
                $this->log(xPDO::LOG_LEVEL_ERROR, "An exception occurred calling {$className}::{$method}() - " . $e->getMessage());
            }
        } else {
            $this->log(xPDO::LOG_LEVEL_ERROR, "{$class}::{$method}() is not a valid static method.");
        }
        return $return;
    }
public function call ( $ class , $ method , array $ args = array ( ) , $ transient = false ) { $ return = null ; $ callback = '' ; if ( $ transient ) { $ className = $ this -> loadClass ( $ class , '' , false , true ) ; if ( $ className ) { $ callback = array ( $ className , $ method ) ; } } else { $ className = $ this -> loadClass ( $ class ) ; if ( $ className ) { $ className = $ this -> getPlatformClass ( $ className ) ; $ callback = array ( $ className , $ method ) ; } } if ( ! empty ( $ callback ) && is_callable ( $ callback ) ) { try { $ return = $ className :: $ method ( ... $ args ) ; } catch ( \ Exception $ e ) { $ this -> log ( xPDO :: LOG_LEVEL_ERROR , "An exception occurred calling {$className}::{$method}() - " . $ e -> getMessage ( ) ) ; } } else { $ this -> log ( xPDO :: LOG_LEVEL_ERROR , "{$class}::{$method}() is not a valid static method." ) ; } return $ return ; }
Call a static method from a valid package class with arguments.

Will always search for database-specific class files first.

@param string $class The name of a class to to get the static method from.
@param string $method The name of the method you want to call.
@param array $args An array of arguments for the method.
@param boolean $transient Indicates if the class has dbtype derivatives. Set to true if you
want to use on classes not derived from xPDOObject.
@return mixed|null The callback method's return value or null if no valid method is found.
Call a static method from a valid package class with arguments .