diff options
author | Emiel Bruijntjes <emiel.bruijntjes@copernica.com> | 2015-01-11 13:49:15 +0100 |
---|---|---|
committer | Emiel Bruijntjes <emiel.bruijntjes@copernica.com> | 2015-01-11 13:49:15 +0100 |
commit | ae9d580fe7a79052d614b7d48d8feb54836fe334 (patch) | |
tree | 874ed8c758b51a8c6f1b280620d70725f5936ac1 /include/file.h | |
parent | 1c663ea116121469e37ad2cb9480387c16c0236b (diff) |
added include(), require(), include_once() and require_once() methods, based on the Php::File class (feature built based on inspiration from pull request #147);
Diffstat (limited to 'include/file.h')
-rw-r--r-- | include/file.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/include/file.h b/include/file.h index 6e24516..7029bb6 100644 --- a/include/file.h +++ b/include/file.h @@ -55,7 +55,19 @@ public: virtual ~File(); /** - * Include the file once + * Does the file exist? + * @return boolean + */ + bool exists(); + + /** + * Is this a valid file? + * @return boolean + */ + bool valid(); + + /** + * Execute the file once (do nothing if the file already was executed) * @return Php::Value */ Value once(); @@ -78,6 +90,12 @@ private: * @var Opcodes */ Opcodes *_opcodes = nullptr; + + /** + * Compile the file + * @return bool + */ + bool compile(); }; |