<?php namespace App\Media\MSVideo; use Illuminate\Support\Collection; use App\Media\MSVideo; abstract class Container extends MSVideo { protected int $offset; protected int $size; protected string $filename; protected bool $be; // Endian, TRUE=Big Endian protected Collection $cache; protected Collection $containers; public function __construct(int $offset,int $size,string $filename,int $be) { $this->offset = $offset; // Quick validation if ($size < 0) throw new \Exception(sprintf('Container cannot be negative. (%d)',$size)); $this->size = $size; $this->filename = $filename; $this->cache = collect(); } }