aboutsummaryrefslogtreecommitdiffstats
path: root/src/vpp-api/vom/sub_interface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vpp-api/vom/sub_interface.cpp')
-rw-r--r--src/vpp-api/vom/sub_interface.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/vpp-api/vom/sub_interface.cpp b/src/vpp-api/vom/sub_interface.cpp
index 94baa3d2ecc..42f75791968 100644
--- a/src/vpp-api/vom/sub_interface.cpp
+++ b/src/vpp-api/vom/sub_interface.cpp
@@ -29,6 +29,19 @@ sub_interface::sub_interface(const interface& parent,
{
}
+/**
+ * Construct a new object matching the desried state
+ */
+sub_interface::sub_interface(const interface& parent,
+ admin_state_t state,
+ const route_domain& rd,
+ vlan_id_t vlan)
+ : interface(mk_name(parent, vlan), parent.type(), state, rd)
+ , m_parent(parent.singular())
+ , m_vlan(vlan)
+{
+}
+
sub_interface::~sub_interface()
{
sweep();