bool c4_RemapWithViewer::GetItem(int row_, int col_, c4_Bytes &buf_) {
  const c4_Property &map = _argView.NthProperty(0);
  d4_assert(map.Type() == 'I');

  row_ = ((const c4_IntProp &)map)(_argView[row_]);

  return _parent.GetItem(row_, col_, buf_);
}
Exemple #2
0
bool c4_GroupByViewer::GetItem(int row_, int col_, c4_Bytes& buf_)
{
  if (col_ < _keys.NumProperties())
    return _sorted.GetItem(_map.GetAt(row_), col_, buf_);

  d4_assert(col_ == _keys.NumProperties());
  
  t4_i32 count;
  switch (_result.Type())
  {
    case 'I': count = _map.GetAt(row_ + 1) - _map.GetAt(row_);
          buf_ = c4_Bytes (&count, sizeof count, true);
          break;
    case 'V': _temp = _sorted.Slice(_map.GetAt(row_), _map.GetAt(row_ + 1))
                .ProjectWithout(_keys);
          buf_ = c4_Bytes (&_temp, sizeof _temp, true);
          break;
    default:  d4_assert(0);
  }

  return true;
}
Exemple #3
0
bool c4_RenameViewer::GetItem(int row_, int col_, c4_Bytes& buf_)
{
  return _parent.GetItem(row_, col_, buf_);
}
Exemple #4
0
bool c4_SliceViewer::GetItem(int row_, int col_, c4_Bytes& buf_)
{
  row_ = _first + _step * (_step > 0 ? row_ : row_ - GetSize() + 1);

  return _parent.GetItem(row_, col_, buf_);
}