]> git.mxchange.org Git - hub.git/blobdiff - application/hub/interfaces/wrapper/class_NodeDhtWrapper.php
Continued: ;-)
[hub.git] / application / hub / interfaces / wrapper / class_NodeDhtWrapper.php
index 64eea869518059395207e6a79afb61115b681e50..9b8ba7a8d2fef423cb81ae6a8a2bad1556eb6e57 100644 (file)
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
  */
 interface NodeDhtWrapper extends DatabaseWrapper {
+       /**
+        * Static getter for an array of all DHT database entries
+        *
+        * @return      $elements       All elements for the DHT dabase
+        */
+       static function getAllElements ();
+
        /**
         * Getter for result instance for unpublished entries
         *
@@ -127,12 +134,37 @@ interface NodeDhtWrapper extends DatabaseWrapper {
        function initEntryPublication ();
 
        /**
-        * Removes non-public data from given array.
+        * Removes non-data from given array.
         *
-        * @param       $data   An array with possible non-public data that needs to be removed.
-        * @return      $data   A cleaned up array with only public data.
+        * @param       $data   An array with possible non-data that needs to be removed.
+        * @return      $data   A cleaned up array with only data.
+        */
+       function removeNonPublicDataFromArray(array $data);
+
+       /**
+        * Find recipients for given package data and returns it as a result instance
+        *
+        * @param       $packageData    An array of valid package data
+        * @return      $recipients             An indexed array with DHT recipients
+        */
+       function getResultFromExcludedSender (array $packageData);
+
+       /**
+        * Find recopients by given key/value pair. First look for the key and if it
+        * matches, compare the value.
+        *
+        * @param       $key                    Key to look for
+        * @param       $value                  Value to compare if key matches
+        * @return      $recipients             An indexed array with DHT recipients
+        */
+       function getResultFromKeyValue ($key, $value);
+
+       /**
+        * Enable DHT bootstrap request acceptance for local node
+        *
+        * @return      void
         */
-       function removeNonPublicDataFromArray (array $data);
+       function enableAcceptDhtBootstrap ();
 }
 
 // [EOF]