public function register($name, FormatInterface $format)
    {
        if (isset($this->formats[$name])) {
            throw new \InvalidArgumentException(sprintf(
                'Formatter with name "%s" is already registered',
                $name
            ));
        }

        $this->formats[$name] = $format;
    }