summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJon Pugh2018-04-04 15:42:02 (GMT)
committerJon Pugh2018-04-04 16:00:01 (GMT)
commit36c9d373a66b8073fbc58be2ede5ffcde3839e88 (patch)
tree69faa769d50f4babbffad8b9c9851fbfbd8020d2
parent19b4723d936c519f6bb4d336d6d2690915a186cd (diff)
Add Conext::hasProperty() method.
-rw-r--r--src/Provision/Context.php15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/Provision/Context.php b/src/Provision/Context.php
index 10b5e54..5d33bf2 100644
--- a/src/Provision/Context.php
+++ b/src/Provision/Context.php
@@ -499,6 +499,21 @@ class Context implements BuilderAwareInterface
}
/**
+ * Whether or not this Context has a property.
+ *
+ * @param $type
+ * @return bool
+ */
+ public function hasProperty($name) {
+ if (isset($this->properties[$name])) {
+ return TRUE;
+ }
+ else {
+ return FALSE;
+ }
+ }
+
+ /**
* Return all properties for this context.
*
* @return array