// Standard ctor - as for BlobReadStream but also specify the offset and number of bytes for the partial read. public PartialBlobReadStream(Stream s, FPTag t, long offset, long numBytes) { // We cannot call the base constructor because we need use the additional offset and numBytes parameters // Even if we split out some of the functionality using a virtual init method with no // parameters, these paraameters will not be initialized when the virtual function was called // by the base constructor. So we just have to duplicate the (small)initialization code. holdingArea = s; theTag = t; myCallbacks = new Callbacks(holdingArea, 16 * 1024); fpStream = new FPGenericStream(holdingArea, FPStream.StreamDirection.OutputFromCentera, myCallbacks, IntPtr.Zero); fpStream.StreamLen = numBytes; blobThread = new Thread(delegate() { theTag.BlobReadPartial(fpStream, offset, numBytes); }); blobThread.Name = "PartialBlobReadThread"; blobThread.Start(); }