2008-04-29 12:55:25 +00:00
|
|
|
#include <qpdf/Pipeline.hh>
|
2009-09-26 18:36:04 +00:00
|
|
|
#include <stdexcept>
|
2008-04-29 12:55:25 +00:00
|
|
|
|
|
|
|
Pipeline::Pipeline(char const* identifier, Pipeline* next) :
|
|
|
|
identifier(identifier),
|
2020-04-03 15:59:29 +00:00
|
|
|
next(next)
|
2008-04-29 12:55:25 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
Pipeline::~Pipeline()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
Pipeline*
|
|
|
|
Pipeline::getNext(bool allow_null)
|
|
|
|
{
|
2020-04-03 15:59:29 +00:00
|
|
|
if ((this->next == 0) && (! allow_null))
|
2008-04-29 12:55:25 +00:00
|
|
|
{
|
2009-09-26 18:36:04 +00:00
|
|
|
throw std::logic_error(
|
2008-04-29 12:55:25 +00:00
|
|
|
this->identifier +
|
|
|
|
": Pipeline::getNext() called on pipeline with no next");
|
|
|
|
}
|
2020-04-03 15:59:29 +00:00
|
|
|
return this->next;
|
2008-04-29 12:55:25 +00:00
|
|
|
}
|
2019-08-28 02:10:11 +00:00
|
|
|
|
|
|
|
std::string
|
|
|
|
Pipeline::getIdentifier() const
|
|
|
|
{
|
|
|
|
return this->identifier;
|
|
|
|
}
|