summaryrefslogtreecommitdiff
path: root/include/classinfo.h
diff options
context:
space:
mode:
authorMartijn Otto <martijn.otto@copernica.com>2014-02-14 16:30:23 +0100
committerMartijn Otto <martijn.otto@copernica.com>2014-02-14 16:30:23 +0100
commit06aa5fd5afaba69544b93654fb0a4f9c2651306e (patch)
tree99cd2ee120786a84531b450f9ef64e2319ef5192 /include/classinfo.h
parent5c23fee5ce58ae66a70f3bd19a1dc2dff7220f13 (diff)
Merged pull request #14
Diffstat (limited to 'include/classinfo.h')
-rw-r--r--include/classinfo.h22
1 files changed, 15 insertions, 7 deletions
diff --git a/include/classinfo.h b/include/classinfo.h
index 276bc63..070dcd5 100644
--- a/include/classinfo.h
+++ b/include/classinfo.h
@@ -52,16 +52,16 @@ public:
void initialize();
/**
- * Construct the C++ object
- * @return Base
- */
- virtual Base *construct() = 0;
-
- /**
* Initialize the class
* @param entry
*/
virtual void initialize(struct _zend_class_entry *entry) = 0;
+
+ /**
+ * Construct the C++ object
+ * @return Base
+ */
+ virtual Base *construct() = 0;
/**
* Retrieve the methods
@@ -69,6 +69,11 @@ public:
*/
virtual struct _zend_function_entry *methods() = 0;
+ /**
+ * set access types flags for class
+ */
+ void seFlags(struct _zend_class_entry *entry, int flags);
+
protected:
/**
* The class entry
@@ -130,8 +135,11 @@ public:
* Initialize the class
* @param entry
*/
- virtual void initialize(struct _zend_class_entry *entry)
+ virtual void initialize(struct _zend_class_entry *entry) override
{
+ // set access types flags for class
+ seFlags(entry, _type.getFlags());
+
// pass to the entry
_type.initialize(entry);
}