This is the method, which does the decoding work.

@param $data
@return array
519597
public function decode($data)
    {
        $parser = new Parser();
        $this->arrayData = (array) $parser->parse($data);
        return $this->arrayData;
    }
1288235
public static function encode($data)
    {
        if (is_object($data)) {
            if (method_exists($data, "toArray")) {
                $data = $data->toArray();
            } else {
                $data = (array) $data;
            }
        }

        $encoder = new self($data);
        $encoded = $encoder->doEncode();

        return $encoded;
    }
115820
protected function parseArray($data)
    {
        $pattern = '/(\[[^\[\]]*\])/';

        set_error_handler([__CLASS__, 'handleError']);

        while (true) {
            if (!preg_match($pattern, $data, $matches) > 0) {
                break;
            }

            $stringMatches = trim($matches[0]);

            $items = explode(',', $stringMatches);

            $currentData = $this->filterItems($items);


            $data = str_replace($stringMatches, serialize($currentData), $data);
        }

        $result = unserialize($data);

        restore_error_handler();

        return $result;
    }
522502
private function safe_decode($data) {
    if (is_array($data)) {
      return array_map(array($this, 'safe_decode'), $data);
    } else if (is_scalar($data)) {
      return rawurldecode($data);
    } else {
      return '';
    }
  }
885589
public function decode(string $data): array
    {
        $document = new \DOMDocument();

        if (!@$document->loadXML($data)) {
            throw DeserializerRuntimeException::createNotParsable($this->getContentType());
        }

        return $this->decodeNode($document->documentElement);
    }
168304
public function decode(string $data): array
    {
        $rawData = [];
        parse_str($data, $rawData);

        if ('' !== $data && [] === $rawData) {
            throw DeserializerRuntimeException::createNotParsable($this->getContentType());
        }

        return $this->fixValues($rawData);
    }
160374
public function encode($data)
    {
        if ($data !== null) {
            $data = gzencode((string) $data, $this->options['level'], $this->options['mode']);
            if ($data === false) {
                $data = null;
                $this->error = error_get_last()['message'] ?? 'Unknown';
            }
        }

        return $data;
    }
565041
public function getTransformedData($data): array
    {
        if (method_exists($this, 'transform')) {
            // Transformer provides a 'transform' method
            return (array) $this->transform($data);
        }

        // Otherwise, use the withProps method which calls getProps()
        return $this->withProps($data, $this->getProps());
    }
278648
public function decode($data)
    {
        $result = [];
        $offset = 0;
        $length = strlen($data);
        while ($offset < $length)
        {
            if (!strstr(substr($data, $offset), '|'))
            {
                return [];
            }
            $pos = strpos($data, '|', $offset);
            $num = $pos - $offset;
            $varname = substr($data, $offset, $num);
            $offset += $num + 1;
            $dataItem = unserialize(substr($data, $offset));
            $result[$varname] = $dataItem;
            $offset += strlen(serialize($dataItem));
        }
        return $result;
    }
303797
public function decodeOID($data)
    {
        $bin_data      = array();
        $index         = 0;
        $binary_string = '';
        $oid           = array();

        // first two numbers are: (40*x)+y
        // all next chars are 7-bit numbers
        foreach ($data as $key => $value) {
            $bin_data[$index] = bitConv($value);
            $binary_string   .= $bin_data[$index];
            $index++;
        }

        $oid[0] = (int)($data[0] / 0x28);
        $oid[1] = $data[0] % 0x28;

        $elements    = count($bin_data);
        $temp_number = '00000000';

        for ($x = 1; $x < $elements; $x++) {
            $and_temp = $bin_data[$x] & '01111111';

            $temp_number = bitAdd($temp_number, $and_temp);

            if (substr($bin_data[$x], 0, 1) == '0') {
                // This is a final value without
                // a value preceeding it.
                $oid[$x + 1] = decConv($temp_number);
                $temp_number = '';
            } else {
                $temp_number = shiftLeft($temp_number, 7);
            }
        }

        $oid_string = '';

        foreach ($oid as $key => $value) {
            $oid_string .= $value . ".";
        }

        $oid_string = substr($oid_string, 0, -1);

        return $oid_string;
    }
1164711
public static function decode($data)
    {
        if (!is_string($data)) {
            throw new InvalidArgumentException('data must be string');
        }
        if (1 === strlen($data) % 4) {
            throw new InvalidArgumentException('invalid base64 string length');
        }
        $result = base64_decode($data, true);
        if (false === $result) {
            throw new InvalidArgumentException('invalid base64 string');
        }

        return $result;
    }
1033388
public function decode($data)
    {
        list($data, $consumed, $error) = $this->decodeTransform()
            ->transform($data, $context, true);

        if (null !== $error) {
            throw $error;
        }

        return $data;
    }
615480
protected function parseQueryPair(string $data): array
    {
        $data = explode('=', $data, 2);
        if (1 === count($data)) {
            $data[] = '';
        }

        return array_map(__NAMESPACE__ . '\decode', $data);
    }
1046282
public function decodeData($data)
    {
        $output = array();
        while (strlen($data) > 0) {
            preg_match('/(\w+)(\[(\d+)\])?=/', $data, $matches);
            $key = $matches[1];
            $data = substr($data, strlen($matches[0]));

            if (isset($matches[3])) {
                $value = substr($data, 0, $matches[3]);
            } else {
                $next = strpos($data, '&');
                $value = $next === false ? $data : substr($data, 0, $next);
            }

            $data = substr($data, strlen($value) + 1);
            $output[$key] = $value;
        }

        return $output;
    }
183892
protected function encode($data)
    {
        if ($this->getEncoding() === self::ENCODING_BASE64) {
            return base64_encode(serialize($data));
        } else {
            return serialize($data);
        }
    }
1324329
public function decode(string $data, string $contentType): array
    {
        return $this->decoder->decode($data, $contentType);
    }
805359
public static function decodeMimeStringPart(&$data)
    {
        array_shift($data);
        $encode = strtoupper(array_shift($data));
        $type = strtoupper(array_shift($data));
        if ($type === '') {
            return [];
        }

        $str = array_shift($data);

        return [
            $encode => [
                $type => $str
            ]
        ];
    }