* Adds a socket resource to the peer pool
*
* @param $socketResource A valid (must be!) socket resource
+ * @param $connectionType Type of connection, can only be 'incoming', 'outgoing' or 'server'
* @return void
+ * @throws InvalidSocketException If the given resource is invalid or errorous
*/
- function addPeer ($socketResource);
+ function addPeer ($socketResource, $connectionType);
+
+ /**
+ * Getter for array of all socket resource arrays
+ *
+ * @return $sockets An array with all socket arrays
+ */
+ function getAllSockets ();
+
+ /**
+ * Getter for array of all socket resources
+ *
+ * @return $sockets An array with all sockets
+ */
+ function getAllSingleSockets ();
+
+ /**
+ * "Getter" for all sockets of specified type
+ *
+ * @param $connectionType Type of connection, can only be 'incoming', 'outgoing' or 'server'
+ * @return $sockets An array with sockets of given type
+ */
+ function getSocketsByConnectionType ($connectionType);
}
// [EOF]