Signed-off-by: Roland Haeder <roland@mxchange.org>
// Assert on condition
assert(!$this->isPendingDataEmpty());
+ // No markers set?
+ if (!$this->ifStartEndMarkersSet($this->pendingData)) {
+ // This will cause an assertition in next call, so simply wait for more data
+ /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('PACKAGE-ASSEMBLER[' . __METHOD__ . ':' . __LINE__ . ': Pending data of ' . strlen($this->pendingData) . ' Bytes are incomplete, waiting for more ...');
+ return;
+ } // END - if
+
// Init fake array
$packageContent = array(
BaseRawDataHandler::PACKAGE_RAW_DATA => $this->getInputStreamInstance()->streamData($this->pendingData),
* @throws Base64EncodingBadException If the data contains characters which are not in the "alphabet" of BASE64 messages.
*/
public function streamData ($data) {
+ // Debug message
+ /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('RAW-INPUT-STREAM[' . __METHOD__ . ':' . __LINE__ . ': data(' . strlen($data) . ')=' . $data);
+
// Do we have start and end marker again?
assert($this->ifStartEndMarkersSet($data));