From c1da0ac7cca49e0b96dbb359ee48000cb04df15b Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Fri, 14 Feb 2014 18:49:04 +0100 Subject: improve RC constness --- src/MuxElements.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/MuxElements.h') diff --git a/src/MuxElements.h b/src/MuxElements.h index 711f3cf..c416314 100644 --- a/src/MuxElements.h +++ b/src/MuxElements.h @@ -188,10 +188,11 @@ class DabComponent : public RemoteControllable bool isPacketComponent(vector& subchannels); /* Remote control */ - virtual void set_parameter(string parameter, string value); + virtual void set_parameter(const string& parameter, + const string& value); /* Getting a parameter always returns a string. */ - virtual string get_parameter(string parameter); + virtual const string get_parameter(const string& parameter) const; private: @@ -221,10 +222,11 @@ class DabService : public RemoteControllable DabLabel label; /* Remote control */ - virtual void set_parameter(string parameter, string value); + virtual void set_parameter(const string& parameter, + const string& value); /* Getting a parameter always returns a string. */ - virtual string get_parameter(string parameter); + virtual const string get_parameter(const string& parameter) const; private: const DabService& operator=(const DabService& other); -- cgit v1.2.3