* @return void
*/
function addElementsToDataSet (StoreableCriteria $criteriaInstance, Requestable $requestInstance);
+
+ /**
+ * Updates/refreshes node data (e.g. state).
+ *
+ * @return void
+ */
+ function updateNodeData ();
}
// [EOF]
// Once we have that state, set it in the node instance
$nodeInstance->setStateInstance($stateInstance);
+ // Update node data
+ $nodeInstance->updateNodeData();
+
// For any purposes, return the state instance
return $stateInstance;
}
throw new HubAlreadyAnnouncedException($this, self::EXCEPTION_HUB_ALREADY_ANNOUNCED);
} // END - if
- // Set some dummy configuration entries, e.g. node_status
- $this->getConfigInstance()->setConfigEntry('node_status', $this->getStateInstance()->getStateName());
-
// Debug output
$this->debugOutput('HUB-Announcement: START (taskInstance=' . $taskInstance->__toString(). ')');
// Return it
return $addressPort;
}
+
+ /**
+ * Updates/refreshes node data (e.g. state).
+ *
+ * @return void
+ * @todo Find more to do here
+ */
+ public function updateNodeData () {
+ // Set some dummy configuration entries, e.g. node_status
+ $this->getConfigInstance()->setConfigEntry('node_status', $this->getStateInstance()->getStateName());
+ }
}
// [EOF]
* @return $signature Signature as BASE64-encoded string
*/
private function generatePackageSignature ($content, $senderId) {
- // ash content and sender id together, use md5() as last algo
+ // Hash content and sender id together, use md5() as last algo
$hash = md5($this->getCryptoInstance()->hashString($senderId . $content, $this->getNodeId(), false));
// Encrypt the content again with the hash as a key
public function enqueueRawDataFromTemplate (HelpableHub $helperInstance, $protocolName) {
// Get the raw content ...
$content = $helperInstance->getTemplateInstance()->getRawTemplateData();
+ //* DEBUG: */ $this->debugOutput('content(' . strlen($content) . ')=' . $content);
// ... and compress it
$content = $this->getCompressorInstance()->compressStream($content);