public function displayFooter($row, $next_row)
    {
        if ($this->group_by === null) {
            throw new SwatException("Attribute 'group_by' must be set.");
        }

        $group_by = $this->group_by;

        if (
            $next_row === null ||
            !$this->isEqual($row->$group_by, $next_row->$group_by)
        ) {
            $this->displayGroupFooter($row);
        }
    }