aboutsummaryrefslogtreecommitdiff
path: root/src/agent
diff options
context:
space:
mode:
authorSimon Lin <simonlin@google.com>2022-01-04 13:28:26 +0800
committerGitHub <noreply@github.com>2022-01-03 21:28:26 -0800
commit7093d8617ead43b6984ce7b3722aa4150da19d14 (patch)
tree3f7c9ec8f4bb2c16173629dd855cdb5bdc92a448 /src/agent
parent30bf372e519636c44296b7edee721c00918b4490 (diff)
downloadot-br-posix-7093d8617ead43b6984ce7b3722aa4150da19d14.tar.gz
[utils] add `NonCopyable` (#1177)
This commit uses `NonCopyable` to make sure certain objects are never copied.
Diffstat (limited to 'src/agent')
-rw-r--r--src/agent/application.hpp2
-rw-r--r--src/agent/instance_params.hpp4
2 files changed, 4 insertions, 2 deletions
diff --git a/src/agent/application.hpp b/src/agent/application.hpp
index 94a6178b..fe043831 100644
--- a/src/agent/application.hpp
+++ b/src/agent/application.hpp
@@ -73,7 +73,7 @@ namespace otbr {
* This class implements OTBR application management.
*
*/
-class Application
+class Application : private NonCopyable
{
public:
/**
diff --git a/src/agent/instance_params.hpp b/src/agent/instance_params.hpp
index 523f948b..7caca384 100644
--- a/src/agent/instance_params.hpp
+++ b/src/agent/instance_params.hpp
@@ -34,13 +34,15 @@
#ifndef OTBR_AGENT_INSATNCE_PARAMS_HPP_
#define OTBR_AGENT_INSATNCE_PARAMS_HPP_
+#include "common/code_utils.hpp"
+
namespace otbr {
/**
* This class represents the agent instance parameters.
*
*/
-class InstanceParams
+class InstanceParams : private NonCopyable
{
public:
/**