public function apc_add($key, $var = null, $ttl = 0)
    {
        if (is_string($key) && $var === null) {
            throw new \InvalidArgumentException('When $key is set $var cannot be null');
        }

        $code = new Code();
        $code->addStatement(sprintf(
            'return apc_add(%s, %s, %s);',
            var_export($key, true),
            var_export($var, true),
            var_export($ttl, true)
        ));

        return $this->adapter->run($code);
    }