aboutsummaryrefslogtreecommitdiffstats
path: root/messagebus/src/vespa/messagebus/testlib/simplereply.h
blob: 50d7024ac6c24460e1be50f90fb9db50b3141701 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

#include "simplemessage.h"
#include <vespa/messagebus/reply.h>

namespace mbus {

class SimpleReply : public Reply
{
private:
    string _value;
    SimpleReply &operator=(const SimpleReply &);
public:
    using UP = std::unique_ptr<SimpleReply>;
    SimpleReply(const string &str);
    virtual ~SimpleReply();
    void setValue(const string &value);
    const string &getValue() const;
    const string & getProtocol() const override;
    uint32_t getType() const override;

    uint8_t priority() const override { return 8; }
};

} // namespace mbus