* Copyright (c) Huawei Technologies Co., Ltd. 2012-2018. All rights reserved.
*/
#ifndef OMNISTREAM_DUMMYSTREAMPARTITIONER_H
#define OMNISTREAM_DUMMYSTREAMPARTITIONER_H
#include "runtime/io/network/api/writer/RecordWriter.h"
#include "streaming/runtime/io/RecordWriterOutput.h"
class DummyStreamPartitioner : public omnistream::datastream::StreamPartitioner<IOReadableWritable> {
public:
bool isPointWise() const override
{
return false;
}
void setup(int numberOfChannels) override
{
}
int selectChannel(IOReadableWritable* record) override
{
return 0;
}
bool isBroadcast() const override
{
return false;
}
virtual std::unique_ptr<StreamPartitioner<IOReadableWritable>> copy()
{
return nullptr;
};
[[nodiscard]] virtual std::string toString() const
{
return {};
}
};
#endif