Example #1
0
        public void Open(String fileName)
        {
            System.Collections.Generic.List <TapBlock> blockCol = new System.Collections.Generic.List <TapBlock>();

            try
            {
                using (var file = File.OpenRead(fileName))
                {
                    var stream = new BinaryReader(file);
                    while (stream.BaseStream.Position < stream.BaseStream.Length)
                    {
                        var newBlock = new TapBlock(stream);
                        blockCol.Add(newBlock);
                    }
                }
            }
            catch (Exception) { }

            blocks = blockCol.ToArray();
        }
Example #2
0
        protected Byte[] TapeLoad(int bytesToLoad)
        {
            TapBlock currentBlock = currentTape.Blocks[currentTapeBlock++];

            return(currentBlock.Data);
        }