summaryrefslogtreecommitdiff
path: root/include/interface.h
diff options
context:
space:
mode:
authorEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2014-04-02 22:25:45 +0200
committerEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2014-04-02 22:25:45 +0200
commitbbdcdae98979e002476fc1e8296effd0b270928b (patch)
tree8634ff596c4209296a36dd7f8c54d00a8ec29478 /include/interface.h
parent735ec67aeb40e04a2cf47fa7216b2030c66b37fd (diff)
refactored the class and classbase classes, and introduced a classimpl class in the src directory, this is a first step to remove all zend-specific code from the header files, so that we can later have a hhvm backend for the php-cpp library
Diffstat (limited to 'include/interface.h')
-rw-r--r--include/interface.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/interface.h b/include/interface.h
index b0469f4..36f4d50 100644
--- a/include/interface.h
+++ b/include/interface.h
@@ -31,11 +31,15 @@ public:
* Add a - of course abstract - method to the interface
* @param name Name of the method
* @param arguments Optional description of the arguments
+ * @return Interface Same object to allow chaining
*/
- void method(const char *name, const Arguments &arguments = {})
+ Interface &method(const char *name, const Arguments &arguments = {})
{
// call base
ClassBase::method(name, Abstract | Public, arguments);
+
+ // return self
+ return *this;
}
private: