Esempio n. 1
0
void
UnwindPlan::InsertRow (const UnwindPlan::RowSP &row_sp)
{
    collection::iterator it = m_row_list.begin();
    while (it != m_row_list.end()) {
        RowSP row = *it;
        if (row->GetOffset() >= row_sp->GetOffset())
            break;
        it++;
    }
    if (it == m_row_list.end() || (*it)->GetOffset() != row_sp->GetOffset())
        m_row_list.insert(it, row_sp);
}
Esempio n. 2
0
void UnwindPlan::AppendRow(const UnwindPlan::RowSP &row_sp) {
  if (m_row_list.empty() ||
      m_row_list.back()->GetOffset() != row_sp->GetOffset())
    m_row_list.push_back(row_sp);
  else
    m_row_list.back() = row_sp;
}