| 541 | } |
| 542 | |
| 543 | bool RowDescriptor::IsPrefixOf(const RowDescriptor& other_desc) const { |
| 544 | if (tuple_desc_map_.size() > other_desc.tuple_desc_map_.size()) return false; |
| 545 | for (int i = 0; i < tuple_desc_map_.size(); ++i) { |
| 546 | // pointer comparison okay, descriptors are unique |
| 547 | if (tuple_desc_map_[i] != other_desc.tuple_desc_map_[i]) return false; |
| 548 | } |
| 549 | return true; |
| 550 | } |
| 551 | |
| 552 | bool RowDescriptor::Equals(const RowDescriptor& other_desc) const { |
| 553 | if (tuple_desc_map_.size() != other_desc.tuple_desc_map_.size()) return false; |