protected static function formatContainer($container)
    {
        if (!is_array($container)) {
            $container = [$container];
        }

        $instance = array_shift($container);

        if (!$method = array_shift($container)) {
            if ($instance instanceof \ArrayAccess) {
                $method = 'offsetGet';
            } else {
                $method = 'get';
            }
        }

        return [$instance, $method];
    }
protected static function formatContainer($container)
    {
        if (!is_array($container)) {
            $container = [$container];
        }

        $instance = array_shift($container);

        if (!$method = array_shift($container)) {
            if ($instance instanceof \ArrayAccess) {
                $method = 'offsetGet';
            } else {
                $method = 'get';
            }
        }

        return [$instance, $method];
    }
protected static function formatContainer ( $ container ) { if ( ! is_array ( $ container ) ) { $ container = [ $ container ] ; } $ instance = array_shift ( $ container ) ; if ( ! $ method = array_shift ( $ container ) ) { if ( $ instance instanceof \ ArrayAccess ) { $ method = 'offsetGet' ; } else { $ method = 'get' ; } } return [ $ instance , $ method ] ; }
Formats a container param as a callable.

@param mixed $container
@return callable
Formats a container param as a callable .