예제 #1
0
파일: BATBlock.cs 프로젝트: okevin/chama
        public static BATBlockAndIndex GetSBATBlockAndIndex(int offset, HeaderBlock header, List <BATBlock> sbats)
        {
            POIFSBigBlockSize bigBlockSize = header.BigBlockSize;

            int whichSBAT = (int)Math.Floor(1.0 * offset / bigBlockSize.GetBATEntriesPerBlock());
            int index     = offset % bigBlockSize.GetBATEntriesPerBlock();

            return(new BATBlockAndIndex(index, sbats[whichSBAT]));
        }
예제 #2
0
 public HeaderBlockWriter(HeaderBlock headerBlock)
 {
     _header_block = headerBlock;
 }
예제 #3
0
파일: BATBlock.cs 프로젝트: okevin/chama
 public static int CalculateMaximumSize(HeaderBlock header)
 {
     return(CalculateMaximumSize(header.BigBlockSize, header.BATCount));
 }
예제 #4
0
 public HeaderBlockWriter(POIFSBigBlockSize bigBlockSize)
 {
     _header_block = new HeaderBlock(bigBlockSize);
 }