- labels: --> wheat core
The code is inconsistent about when it provides
convenience functions and when not.
For example: The core functionality of getting an object
from a path would entail something like this:
pt::string contextString = "/library/render/context";
Path contextPath(contextString);
ObjectPointer contextOp = NameSpace::path(contextPath);
But the programmer really wants to write just:
ObjectPointer contextOp = NameSpace::path("/library/
render/context");
or perhaps even:
ObjectPointer contextOp("/library/render/context");
To achieve this, the code could rely on a combination of
C++ automatic conversions and convenience functions.
Possible converisons are:
pt::string::string(const char*);
Path::Path(const char*);
Path::Path(const pt::string&);
ObjectPointer::ObjectPointer(const char*);
ObjectPointer::ObjectPointer(const pt::string&);
ObjectPointer::ObjectPointer(const Path&);
Possible convenience functions are:
NameSpace::path(const char*);
NameSpace::path(const pt::string&);
Remember that C++ will only apply one user supplied
conversion function per argument...
This needs some thought and I'm not sure what the right
answer is.