[icinga-checkins] icinga.org: icingaweb2-module-director/feature-ddo-playground: StateList: keep objects

git at icinga.org git at icinga.org
Tue Jul 19 10:31:52 CEST 2016


Module: icingaweb2-module-director
Branch: feature-ddo-playground
Commit: 1fc215c21767831011ab48a4394d49f2b2253a3b
URL:    https://git.icinga.org/?p=icingaweb2-module-director.git;a=commit;h=1fc215c21767831011ab48a4394d49f2b2253a3b

Author: Thomas Gelf <thomas at gelf.net>
Date:   Tue Jun 21 15:04:15 2016 +0200

StateList: keep objects

---

 library/Director/Ddo/StateList.php |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/library/Director/Ddo/StateList.php b/library/Director/Ddo/StateList.php
index 4e27db9..b9a8b7a 100644
--- a/library/Director/Ddo/StateList.php
+++ b/library/Director/Ddo/StateList.php
@@ -28,6 +28,8 @@ class StateList
             $object = $this->createObject($host, $service, $key);
         }
 
+        $this->objects[$key] = $object;
+
         $object->processCheckResult($result);
 
         return $object;
@@ -49,6 +51,11 @@ class StateList
         }
     }
 
+    protected function getObject($key)
+    {
+        return $this->objects[$key];
+    }
+
     protected function hasKey($key)
     {
         return array_key_exists($key, $this->objects);



More information about the icinga-checkins mailing list