CondimentDecorator.hpp 347 字节
Newer Older
L
liu-jianhao 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
#ifndef CONDIMENTDECORATOR_HPP
#define CONDIMENTDECORATOR_HPP

#include "Beverage.hpp"

#include <memory>

class CondimentDecorator : public Beverage {
protected:
    std::unique_ptr<Beverage> beverage;
public:
    CondimentDecorator(std::unique_ptr<Beverage> b) : beverage(std::move(b)) {}
    virtual ~CondimentDecorator() = default;
};

#endif