PLearn 0.1
|
#include <SetOption.h>
Public Types | |
typedef Object | inherited |
Public Member Functions | |
SetOption () | |
virtual void | build () |
Post-constructor. | |
virtual void | makeDeepCopyFromShallowCopy (CopiesMap &copies) |
Transforms a shallow copy into a deep copy. | |
void | apply (PP< Object > obj) |
Will call obj->setOption(name, value) | |
void | apply (PP< Object > obj, const map< string, string > &aliases) |
Will call obj->setOption(name, value); or if name is a key in aliases, it will call obj->setOption(aliases[name], value) | |
virtual string | classname () const |
virtual OptionList & | getOptionList () const |
virtual OptionMap & | getOptionMap () const |
virtual RemoteMethodMap & | getRemoteMethodMap () const |
virtual SetOption * | deepCopy (CopiesMap &copies) const |
Static Public Member Functions | |
static string | _classname_ () |
Declares name and deepCopy methods. | |
static OptionList & | _getOptionList_ () |
static RemoteMethodMap & | _getRemoteMethodMap_ () |
static Object * | _new_instance_for_typemap_ () |
static bool | _isa_ (const Object *o) |
static void | _static_initialize_ () |
static const PPath & | declaringFile () |
Public Attributes | |
string | name |
string | value |
Static Public Attributes | |
static StaticInitializer | _static_initializer_ |
Static Protected Member Functions | |
static void | declareOptions (OptionList &ol) |
Declares this class' options. | |
Private Member Functions | |
void | build_ () |
This does the actual building. |
Definition at line 48 of file SetOption.h.
typedef Object PLearn::SetOption::inherited |
Reimplemented from PLearn::Object.
Definition at line 60 of file SetOption.h.
PLearn::SetOption::SetOption | ( | ) |
Definition at line 45 of file SetOption.cc.
:Object() {}
string PLearn::SetOption::_classname_ | ( | ) | [static] |
Declares name and deepCopy methods.
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
OptionList & PLearn::SetOption::_getOptionList_ | ( | ) | [static] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
RemoteMethodMap & PLearn::SetOption::_getRemoteMethodMap_ | ( | ) | [static] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
Object * PLearn::SetOption::_new_instance_for_typemap_ | ( | ) | [static] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
StaticInitializer SetOption::_static_initializer_ & PLearn::SetOption::_static_initialize_ | ( | ) | [static] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
Will call obj->setOption(name, value)
Definition at line 100 of file SetOption.h.
Will call obj->setOption(name, value); or if name is a key in aliases, it will call obj->setOption(aliases[name], value)
Definition at line 79 of file SetOption.cc.
void PLearn::SetOption::build | ( | ) | [virtual] |
Post-constructor.
The normal implementation should call simply inherited::build(), then this class's build_(). This method should be callable again at later times, after modifying some option fields to change the "architecture" of the object.
Reimplemented from PLearn::Object.
Definition at line 67 of file SetOption.cc.
References PLearn::Object::build(), and build_().
{ inherited::build(); build_(); }
void PLearn::SetOption::build_ | ( | ) | [private] |
This does the actual building.
Reimplemented from PLearn::Object.
Definition at line 63 of file SetOption.cc.
Referenced by build().
{}
string PLearn::SetOption::classname | ( | ) | const [virtual] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
void PLearn::SetOption::declareOptions | ( | OptionList & | ol | ) | [static, protected] |
Declares this class' options.
Reimplemented from PLearn::Object.
Definition at line 54 of file SetOption.cc.
References PLearn::OptionBase::buildoption, PLearn::declareOption(), PLearn::Object::declareOptions(), name, and value.
{ declareOption(ol, "name", &SetOption::name, OptionBase::buildoption, "name of the option to be set"); declareOption(ol, "value", &SetOption::value, OptionBase::buildoption, "value of the option to be set"); inherited::declareOptions(ol); }
static const PPath& PLearn::SetOption::declaringFile | ( | ) | [inline, static] |
Reimplemented from PLearn::Object.
Definition at line 108 of file SetOption.h.
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
OptionList & PLearn::SetOption::getOptionList | ( | ) | const [virtual] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
OptionMap & PLearn::SetOption::getOptionMap | ( | ) | const [virtual] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
RemoteMethodMap & PLearn::SetOption::getRemoteMethodMap | ( | ) | const [virtual] |
Reimplemented from PLearn::Object.
Definition at line 52 of file SetOption.cc.
void PLearn::SetOption::makeDeepCopyFromShallowCopy | ( | CopiesMap & | copies | ) | [virtual] |
Transforms a shallow copy into a deep copy.
Reimplemented from PLearn::Object.
Definition at line 74 of file SetOption.cc.
References PLearn::Object::makeDeepCopyFromShallowCopy().
{ inherited::makeDeepCopyFromShallowCopy(copies); }
Reimplemented from PLearn::Object.
Definition at line 108 of file SetOption.h.
string PLearn::SetOption::name |
Definition at line 66 of file SetOption.h.
Referenced by apply(), and declareOptions().
string PLearn::SetOption::value |
Definition at line 67 of file SetOption.h.
Referenced by apply(), and declareOptions().