public function insertOne(array $record): int
    {
        $method = 'addRecord';
        if (70400 > PHP_VERSION_ID && '' === $this->escape) {
            $method = 'addRFC4180CompliantRecord';
        }

        $record = array_reduce($this->formatters, [$this, 'formatRecord'], $record);
        $this->validateRecord($record);
        $bytes = $this->$method($record);
        if (false !== $bytes && 0 !== $bytes) {
            return $bytes + $this->consolidate();
        }

        throw CannotInsertRecord::triggerOnInsertion($record);
    }