public function parse(&$var, BasicObject $o)
    {
        $o->type = \strtolower(\gettype($var));

        if (!$this->applyPlugins($var, $o, self::TRIGGER_BEGIN)) {
            return $o;
        }

        switch ($o->type) {
            case 'array':
                return $this->parseArray($var, $o);
            case 'boolean':
            case 'double':
            case 'integer':
            case 'null':
                return $this->parseGeneric($var, $o);
            case 'object':
                return $this->parseObject($var, $o);
            case 'resource':
                return $this->parseResource($var, $o);
            case 'string':
                return $this->parseString($var, $o);
            default:
                return $this->parseUnknown($var, $o);
        }
    }
public function parse(&$var, BasicObject $o)
    {
        $o->type = \strtolower(\gettype($var));

        if (!$this->applyPlugins($var, $o, self::TRIGGER_BEGIN)) {
            return $o;
        }

        switch ($o->type) {
            case 'array':
                return $this->parseArray($var, $o);
            case 'boolean':
            case 'double':
            case 'integer':
            case 'null':
                return $this->parseGeneric($var, $o);
            case 'object':
                return $this->parseObject($var, $o);
            case 'resource':
                return $this->parseResource($var, $o);
            case 'string':
                return $this->parseString($var, $o);
            default:
                return $this->parseUnknown($var, $o);
        }
    }
public function parse ( & $ var , BasicObject $ o ) { $ o -> type = \ strtolower ( \ gettype ( $ var ) ) ; if ( ! $ this -> applyPlugins ( $ var , $ o , self :: TRIGGER_BEGIN ) ) { return $ o ; } switch ( $ o -> type ) { case 'array' : return $ this -> parseArray ( $ var , $ o ) ; case 'boolean' : case 'double' : case 'integer' : case 'null' : return $ this -> parseGeneric ( $ var , $ o ) ; case 'object' : return $ this -> parseObject ( $ var , $ o ) ; case 'resource' : return $ this -> parseResource ( $ var , $ o ) ; case 'string' : return $ this -> parseString ( $ var , $ o ) ; default : return $ this -> parseUnknown ( $ var , $ o ) ; } }
Parses a variable into a Kint object structure.

@param mixed       $var The input variable
@param BasicObject $o   The base object

@return BasicObject
Parses a variable into a Kint object structure .