diff options
author | Mohsin Kazmi <sykazmi@cisco.com> | 2017-12-13 19:31:02 +0100 |
---|---|---|
committer | Neale Ranns <nranns@cisco.com> | 2017-12-14 15:03:11 +0000 |
commit | 810bea18065c2477ed561ed7d835aaf4221c5749 (patch) | |
tree | 3ec72874172d11f107c32b662c52e2a5962af896 | |
parent | fad3fb362cc39fdfcb83e2f8a04e5a7b5a4403ca (diff) |
vom: acl-list: Add comparison operator - for UT
Change-Id: I341f522b46dd85fb3b1dd43fd125513f16f89171
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
-rw-r--r-- | src/vpp-api/vom/acl_list.hpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/vpp-api/vom/acl_list.hpp b/src/vpp-api/vom/acl_list.hpp index 0835cea5d48..ff3eeeb21b2 100644 --- a/src/vpp-api/vom/acl_list.hpp +++ b/src/vpp-api/vom/acl_list.hpp @@ -148,6 +148,18 @@ public: static void remove(const handle_t& handle) { m_hdl_db.erase(handle); } + const key_t& key() const { return m_key; } + + const rules_t& rules() const { return m_rules; } + + /** + * Comparison operator - for UT + */ + bool operator==(const list& l) const + { + return (key() == l.key() && rules() == l.rules()); + } + private: /** * Class definition for listeners to OM events |