blob: 023259143a4933100ba6f40ca79cd177c6e744de (
plain)
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
/* -*- C++ -*-; c-basic-offset: 4; indent-tabs-mode: nil */
/*
* Copyright (c) 2018 Cisco Systems, Inc. and others. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v1.0 which accompanies this distribution,
* and is available at http://www.eclipse.org/legal/epl-v10.html
*/
#ifndef __VPP_RUNTIME_H__
#define __VPP_RUNTIME_H__
#include <opflexagent/Agent.h>
#include "VppIdGen.hpp"
#include "VppUplink.hpp"
#include "VppVirtualRouter.hpp"
namespace VPP
{
struct Runtime
{
Runtime(opflexagent::Agent &agent_, opflexagent::IdGenerator &idGen)
: agent(agent_)
, id_gen(idGen)
, uplink(agent)
{
}
opflexagent::PolicyManager &
policy_manager()
{
return agent.getPolicyManager();
}
/**
* Referene to the uber-agent
*/
opflexagent::Agent &agent;
/**
* ID generator instance
*/
IdGen id_gen;
/**
* Uplink interface manager
*/
Uplink uplink;
/**
* Virtual Router Settings
*/
std::shared_ptr<VirtualRouter> vr;
/**
* System Name
*/
std::string system_name;
/**
* Transport or stitch mode
*/
bool is_transport_mode;
private:
Runtime(const Runtime &);
};
}; // namespace VPP
#endif
|