From 2ed3e09b30357cbab2137056d51caf6bac3f48c6 Mon Sep 17 00:00:00 2001 From: Andreas Stöckel Date: Wed, 14 Jan 2015 22:04:55 +0100 Subject: Added RttiType::hasProperty and RttiType::hasMethod function --- src/core/common/Rtti.hpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'src/core/common/Rtti.hpp') diff --git a/src/core/common/Rtti.hpp b/src/core/common/Rtti.hpp index 6449c75..3549474 100644 --- a/src/core/common/Rtti.hpp +++ b/src/core/common/Rtti.hpp @@ -435,6 +435,23 @@ public: */ std::shared_ptr getProperty(const std::string &name) const; + /** + * Returns true if a method with the given name is registered for this type. + * + * @param name is the name of the method that should be looked up. + * @return true if a method with this name exists, false otherwise. + */ + bool hasMethod(const std::string &name) const; + + /** + * Returns true if a property with the given name is registered for this + * type. + * + * @param name is the name of the property that should be looked up. + * @return true if a property with this name exists, false otherwise. + */ + bool hasProperty(const std::string &name) const; + }; /** -- cgit v1.2.3