1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-08-01 06:46:55 +03:00

clang format apply

This commit is contained in:
Leonid Fedorov
2022-01-21 16:43:49 +00:00
parent 6b6411229f
commit 04752ec546
1376 changed files with 393460 additions and 412662 deletions

View File

@ -24,65 +24,66 @@ using namespace utils;
namespace joiner
{
Joiner::Joiner(bool ia) : _includeAll(ia), _inPM(false), _pool(new SimplePool)
{
SimpleAllocator<pair<uint64_t const, uint64_t> > alloc(_pool);
h.reset(new hash_t(10, hash_t::hasher(), hash_t::key_equal(), alloc));
// cout << "Joiner()\n";
SimpleAllocator<pair<uint64_t const, uint64_t> > alloc(_pool);
h.reset(new hash_t(10, hash_t::hasher(), hash_t::key_equal(), alloc));
// cout << "Joiner()\n";
}
Joiner::Joiner()
{ }
{
}
Joiner::Joiner(const Joiner& j)
{ }
{
}
Joiner& Joiner::operator=(const Joiner& j)
{
return *this;
return *this;
}
Joiner::~Joiner()
{
// cout << "~Joiner()\n";
// get rid of the hash table first
h.reset();
// delete _pool;
// _pool = NULL;
// cout << "~Joiner()\n";
// get rid of the hash table first
h.reset();
// delete _pool;
// _pool = NULL;
}
boost::shared_ptr<vector<ElementType> > Joiner::getSortedMatches()
{
boost::shared_ptr<vector<ElementType> > ret;
iterator it;
boost::shared_ptr<vector<ElementType> > ret;
iterator it;
ret.reset(new vector<ElementType>());
ret.reset(new vector<ElementType>());
for (it = begin(); it != end(); ++it)
if (it->second & MSB)
ret->push_back(ElementType(it->second & ~MSB, it->first));
for (it = begin(); it != end(); ++it)
if (it->second & MSB)
ret->push_back(ElementType(it->second & ~MSB, it->first));
sort<vector<ElementType>::iterator>(ret->begin(), ret->end());
return ret;
sort<vector<ElementType>::iterator>(ret->begin(), ret->end());
return ret;
}
boost::shared_ptr<std::vector<joblist::ElementType> > Joiner::getSmallSide()
{
boost::shared_ptr<vector<ElementType> > ret;
iterator it;
boost::shared_ptr<vector<ElementType> > ret;
iterator it;
ret.reset(new vector<ElementType>());
ret.reset(new vector<ElementType>());
for (it = begin(); it != end(); ++it)
ret->push_back(ElementType(it->second & ~MSB, it->first));
for (it = begin(); it != end(); ++it)
ret->push_back(ElementType(it->second & ~MSB, it->first));
return ret;
return ret;
}
void Joiner::doneInserting()
{
//sort here if the data structure is a vector
// sort here if the data structure is a vector
}
}
} // namespace joiner