optional method naming in constructor
This commit is contained in:
parent
e1faba699e
commit
49a446c5aa
|
@ -30,13 +30,15 @@ namespace OSC {
|
|||
/**
|
||||
* @brief Method::Method
|
||||
* @param parent
|
||||
* @param name
|
||||
*/
|
||||
Method::Method(Method *parent)
|
||||
Method::Method(Method *parent, std::string name)
|
||||
: parent_(parent)
|
||||
, name_("")
|
||||
{
|
||||
if (parent)
|
||||
parent->addChild(this);
|
||||
setName(name);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ namespace OSC {
|
|||
class Method
|
||||
{
|
||||
public:
|
||||
explicit Method(Method *parent = nullptr);
|
||||
explicit Method(Method *parent = nullptr, std::string name = "");
|
||||
virtual ~Method();
|
||||
|
||||
virtual void addChild(Method *child);
|
||||
|
|
Loading…
Reference in New Issue