use Org\Shipsimu\Hub\Factory\FilterChain\Package\PackageFilterChainFactory;
use Org\Shipsimu\Hub\Factory\Handler\Message\MessageTypeHandlerFactory;
use Org\Shipsimu\Hub\Factory\Information\Connection\ConnectionInfoFactory;
+use Org\Shipsimu\Hub\Factory\Network\PackageDataFactory;
use Org\Shipsimu\Hub\Factory\Node\NodeObjectFactory;
use Org\Shipsimu\Hub\Handler\BaseHubHandler;
use Org\Shipsimu\Hub\Handler\Network\RawData\HandleableRawData;
assert($this->getSessionId() != '');
// Init package instance
- $packageInstance = PackageDataFactory::createDeliverPackageInstance();
+ $packageInstance = PackageDataFactory::createPackageDataInstance();
// Set all data
$packageInstance->setSenderAddress($this->getSessionId());
//* DEBUG-DIE: */ $infoInstance->debugInstance();
// Create a faked package data instance
- $packageInstance = DeliverPackageFactory::createDeliverPackageInstance();
+ $packageInstance = PackageDataFactory::createPackageDataInstance();
// Set all required data
$packageInstance->setSenderAddres($peerAddress . $peerSuffix);
*/
class PackageData extends BaseHubSystem implements DeliverablePackage, Registerable {
+ /**
+ * Content hash
+ */
+ private $contentHash;
+
+ /**
+ * Package content
+ */
+ private $packageContent;
+
/**
* An instance of a SplFileInfo class
*/
/**
* Getter for socket type
*
- * @return $socketFile Stocket type
+ * @return $socketType Stocket type
*/
public function getSocketType () {
return $this->socketType;
/**
* Setter for socket type
*
- * @param $socketType Socket type
+ * @param $socketType Socket type
* @return void
*/
public function setSocketType ($socketType) {
$this->socketType = $socketType;
}
+ /**
+ * Getter for package content
+ *
+ * @return $packageContent Package content
+ */
+ public function getPackageContent () {
+ return $this->packageContent;
+ }
+
+ /**
+ * Setter for package content
+ *
+ * @param $packageContent Package content
+ * @return void
+ */
+ public function setPackageContent ($packageContent) {
+ $this->packageContent = $packageContent;
+ }
+
+ /**
+ * Getter for content hash
+ *
+ * @return $contentHash Content hash
+ */
+ public function getContentHash () {
+ return $this->contentHash;
+ }
+
+ /**
+ * Setter for content hash
+ *
+ * @param $contentHash Content hash
+ * @return void
+ */
+ public function setContentHash ($contentHash) {
+ $this->contentHash = $contentHash;
+ }
+
}