public function transform($array)
    {
        if (null === $array) {
            return '';
        }

        if (!is_array($array)) {
            throw new TransformationFailedException('Expected an array.');
        }

        foreach ($array as &$value) {
            $value = sprintf('%s%s%s',
                str_repeat(' ', $this->paddingLeft),
                $value,
                str_repeat(' ', $this->paddingRight)
            );
        }

        $string = trim(implode($this->delimiter, $array));

        return $string;
    }