DOM: Dead code removal
This commit is contained in:
28
src/DOM.cpp
28
src/DOM.cpp
@@ -50,17 +50,6 @@ DOM::~DOM ()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
const std::vector <std::string> DOM::get_references () const
|
|
||||||
{
|
|
||||||
return {"context.program",
|
|
||||||
"context.args",
|
|
||||||
"context.width",
|
|
||||||
"context.height",
|
|
||||||
"system.version",
|
|
||||||
"system.os"};
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
// DOM Supported References:
|
// DOM Supported References:
|
||||||
// rc.<name>
|
// rc.<name>
|
||||||
@@ -448,20 +437,3 @@ bool DOM::get (const std::string& name, const Task& task, Variant& value)
|
|||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
void DOM::set (const std::string& name, const Variant& value)
|
|
||||||
{
|
|
||||||
int len = name.length ();
|
|
||||||
|
|
||||||
// rc. --> context.config
|
|
||||||
if (len > 3 &&
|
|
||||||
name.substr (0, 3) == "rc.")
|
|
||||||
{
|
|
||||||
context.config.set (name.substr (3), (std::string) value);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Unrecognized --> error.
|
|
||||||
else
|
|
||||||
throw format (STRING_DOM_CANNOT_SET, name);
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
|
|||||||
@@ -38,10 +38,8 @@ public:
|
|||||||
DOM ();
|
DOM ();
|
||||||
~DOM ();
|
~DOM ();
|
||||||
|
|
||||||
const std::vector <std::string> get_references () const;
|
|
||||||
bool get (const std::string&, Variant&);
|
bool get (const std::string&, Variant&);
|
||||||
bool get (const std::string&, const Task&, Variant&);
|
bool get (const std::string&, const Task&, Variant&);
|
||||||
void set (const std::string&, const Variant&);
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user