aboutsummaryrefslogtreecommitdiffstats
path: root/messagebus/src/vespa/messagebus/routable.cpp
blob: 4f90a018f081a6ece821ff984d6851cafc5140c6 (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
28
29
30
31
32
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "emptyreply.h"
#include "errorcode.h"
#include "ireplyhandler.h"

namespace mbus {

Routable::Routable() :
    _context(),
    _stack(),
    _trace()
{ }

Routable::~Routable() = default;

void
Routable::discard()
{
    _context = Context();
    _stack.discard();
    _trace.clear();
}

void
Routable::swapState(Routable &rhs)
{
    std::swap(_context, rhs._context);
    _stack.swap(rhs._stack);
    _trace.swap(rhs._trace);
}

} // namespace mbus