protected function parseVersion($version, $prefix)
    {
        $response = [];

        if (preg_match('%(?<major>\d+)((\.(?<minor>\d+)((\.(?<patch>\d+))|$))|$)%', $version, $match)) {
            $pieces = [];

            foreach ($match as $key => $value) {
                if ($key === 'major' || $key === 'minor' || $key === 'patch') {
                    $pieces[] = $response[$prefix . 'Version' . ucfirst($key)] = (int) $value;
                }
            }

            if ( ! empty($pieces)) {
                $response[$prefix . 'Version'] = implode('.', $pieces);
            }
        }

        return $response;
    }