aboutsummaryrefslogtreecommitdiffstats
path: root/src/vpp-api/vom/acl_binding_cmds.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vpp-api/vom/acl_binding_cmds.cpp')
-rw-r--r--src/vpp-api/vom/acl_binding_cmds.cpp60
1 files changed, 58 insertions, 2 deletions
diff --git a/src/vpp-api/vom/acl_binding_cmds.cpp b/src/vpp-api/vom/acl_binding_cmds.cpp
index 534f7868a08..8c33cd47b79 100644
--- a/src/vpp-api/vom/acl_binding_cmds.cpp
+++ b/src/vpp-api/vom/acl_binding_cmds.cpp
@@ -40,6 +40,17 @@ l3_bind_cmd::issue(connection& con)
}
template <>
+std::string
+l3_bind_cmd::to_string() const
+{
+ std::ostringstream s;
+ s << "l3-acl-bind:[" << m_direction.to_string()
+ << " itf:" << m_itf.to_string() << " acl:" << m_acl.to_string() << "]";
+
+ return (s.str());
+}
+
+template <>
rc_t
l3_unbind_cmd::issue(connection& con)
{
@@ -59,6 +70,17 @@ l3_unbind_cmd::issue(connection& con)
}
template <>
+std::string
+l3_unbind_cmd::to_string() const
+{
+ std::ostringstream s;
+ s << "l3-acl-unbind:[" << m_direction.to_string()
+ << " itf:" << m_itf.to_string() << " acl:" << m_acl.to_string() << "]";
+
+ return (s.str());
+}
+
+template <>
rc_t
l3_dump_cmd::issue(connection& con)
{
@@ -75,6 +97,13 @@ l3_dump_cmd::issue(connection& con)
}
template <>
+std::string
+l3_dump_cmd::to_string() const
+{
+ return ("l3-acl-bind-dump");
+}
+
+template <>
rc_t
l2_bind_cmd::issue(connection& con)
{
@@ -83,7 +112,6 @@ l2_bind_cmd::issue(connection& con)
auto& payload = req.get_request().get_payload();
payload.sw_if_index = m_itf.value();
payload.is_add = 1;
- // payload.is_input = (m_direction == direction_t::INPUT ? 1 : 0);
payload.acl_index = m_acl.value();
VAPI_CALL(req.execute());
@@ -94,6 +122,17 @@ l2_bind_cmd::issue(connection& con)
}
template <>
+std::string
+l2_bind_cmd::to_string() const
+{
+ std::ostringstream s;
+ s << "l2-acl-bind:[" << m_direction.to_string()
+ << " itf:" << m_itf.to_string() << " acl:" << m_acl.to_string() << "]";
+
+ return (s.str());
+}
+
+template <>
rc_t
l2_unbind_cmd::issue(connection& con)
{
@@ -102,7 +141,6 @@ l2_unbind_cmd::issue(connection& con)
auto& payload = req.get_request().get_payload();
payload.sw_if_index = m_itf.value();
payload.is_add = 0;
- // payload.is_input = (m_direction == direction_t::INPUT ? 1 : 0);
payload.acl_index = m_acl.value();
VAPI_CALL(req.execute());
@@ -113,6 +151,17 @@ l2_unbind_cmd::issue(connection& con)
}
template <>
+std::string
+l2_unbind_cmd::to_string() const
+{
+ std::ostringstream s;
+ s << "l2-acl-unbind:[" << m_direction.to_string()
+ << " itf:" << m_itf.to_string() << " acl:" << m_acl.to_string() << "]";
+
+ return (s.str());
+}
+
+template <>
rc_t
l2_dump_cmd::issue(connection& con)
{
@@ -128,6 +177,13 @@ l2_dump_cmd::issue(connection& con)
return rc_t::OK;
}
+template <>
+std::string
+l2_dump_cmd::to_string() const
+{
+ return ("l2-acl-bind-dump");
+}
+
}; // namespace binding_cmds
}; // namespace ACL
}; // namespace VOM