Class TextInterface::GetFunction

template<class C, class Get>
class GetFunction : public TextInterface::Attribute<C>

Get is function object that receives C* and returns some type.

This class adapts a function on C* to behave like an attribute of C

Subclassed by TextInterface::GetSetFunction< C, Get, Set >

Public Functions

inline GetFunction(const std::string &_name, Get _get)

Constructor.

inline GetFunction(const GetFunction &copy)

Copy constructor.

inline virtual Attribute<C> *clone() const

Return a clone.

inline virtual std::string get_name() const

Get the name of the attribute.

inline virtual std::string get_description() const

Get the description of the attribute.

inline virtual void set_description(const std::string &d)

Get the description of the attribute.

inline virtual std::string get_detailed_description() const

Get the detailed description of the attribute.

inline virtual void set_detailed_description(const std::string &d)

Get the detailed description of the attribute.

inline virtual std::string get_value(const C *ptr) const

Get the value of the attribute.

inline virtual void set_value(C*, const std::string&)

Set the value of the attribute.

inline virtual void set_modifiers(const std::string &modifiers) const

Parse any modifiers that will alter the behaviour of the output stream.

inline virtual void reset_modifiers() const

Reset any output stream modifiers.