private function insertChunksFromBytes($bytes, $record)
    {
        $chunkSize = $record['chunkSize'];
        $fileId = $record['_id'];
        $i = 0;

        $chunks = str_split($bytes, $chunkSize);
        foreach ($chunks as $chunk) {
            $this->insertChunk($fileId, $chunk, $i++);
        }
    }
private function insertChunksFromBytes($bytes, $record)
    {
        $chunkSize = $record['chunkSize'];
        $fileId = $record['_id'];
        $i = 0;

        $chunks = str_split($bytes, $chunkSize);
        foreach ($chunks as $chunk) {
            $this->insertChunk($fileId, $chunk, $i++);
        }
    }
private function insertChunksFromBytes ( $ bytes , $ record ) { $ chunkSize = $ record [ 'chunkSize' ] ; $ fileId = $ record [ '_id' ] ; $ i = 0 ; $ chunks = str_split ( $ bytes , $ chunkSize ) ; foreach ( $ chunks as $ chunk ) { $ this -> insertChunk ( $ fileId , $ chunk , $ i ++ ) ; } }
Splits a string into chunks and writes them to the database

@param string $bytes
@param array $record
Splits a string into chunks and writes them to the database