public function batch_insert($rows, $timestamp=null, $ttl=null, $consistency_level=null) {
        if ($timestamp === null)
            $timestamp = Clock::get_time();

        $cfmap = array();
        if ($this->insert_format == self::DICTIONARY_FORMAT) {
            foreach($rows as $key => $columns) {
                $packed_key = $this->pack_key($key, $handle_serialize=true);
                $ttlRow = $this->get_ttl($ttl, $packed_key);
                $cfmap[$packed_key][$this->column_family] =
                    $this->make_mutation($columns, $timestamp, $ttlRow);
            }
        } else if ($this->insert_format == self::ARRAY_FORMAT) {
            foreach($rows as $row) {
                list($key, $columns) = $row;
                $packed_key = $this->pack_key($key);
                $ttlRow = $this->get_ttl($ttl, $packed_key);
                $cfmap[$packed_key][$this->column_family] =
                    $this->make_mutation($columns, $timestamp, $ttlRow);
            }
        } else {
            throw new UnexpectedValueException("Bad insert_format selected");
        }

        return $this->pool->call("batch_mutate", $cfmap, $this->wcl($consistency_level));
    }