LZW的观众,

,代码显示一个LZH文件的内容,来源:赃物的支持团队,计划lzhview;,用途,  DOS,CRT;,const,  bsize = 4096;} { I/O缓冲区的大小,类型lzhhead =记录,                 hsize:                 fill1:字节,字节;;,                 方法:数组[ 1 .. 5 ]字符;,                 compsize:LongInt;,                 ucompsize:LongInt;,                 dos_dt:LongInt;,                 fill2:词;,                 filenamelen:字节;,                 文件名:AR射线[ 1。焦炭12 ];,               端;,VaR lzh1:lzhhead;,    DT:日期时间;,    fsize,L,C,F:    LongInt;文件;,    buff:阵列[ 1 ] .. bsize字节;,    日期:弦[ 8 ];{格式化日期年/月/日},    时间:弦[ 6 ];{ ";时间为HH:毫米},    RES:词;,    导演:dirstr;,    名:namestr;,    分机:extstr;,    lzhstring,,    SNAME:字符串,    ;退出:布尔;,    申银万国:指针;,功能上(ST:字符串):字符串,整数;VaR;我,开始,  我:= 1尺(ST)做某事[我]:= Upcase(ST [我]);,  上:= ST;,end;, Function ord_to_str(i:LongInt;j:Byte):String;, Var c:String;, begin,   str(i,c);,   While length(c) 0 then,       begin,         Move (FileNameLen,SNAME,FileNameLen+1);,         UnPackTime (Dos_DT,DT);,         FSize := CompSize,       end,     else QUIT := True, end; { GET_LZH_ENTRY }, Procedure DO_LZH (FN : String);, Var fnstr, LZHMeth : String;,     fls,totu,totc : LongInt;, begin , ,   totu:=0; totc:=0; fls:=0;,   Assign (F,FN);,   {$I-} Reset (F,1); {$I+},   if Ioresult<>0 then,     begin,       Writeln(upper(FN)+' not found');,       Exit;,     end;,   FSize := FileSize(F);,   C := 0;,   QUIT := False;,   Writeln('LZH File : '+upper(FN));,   Writeln;,   Writeln(' Filename OrigSize CompSize Method Date ',   +' Time');,   Writeln('------------ -------- -------- -------- --------',   +' ------');,   Repeat,     GET_LZH_ENTRY;,     if not QUIT then,       begin,         FSplit (SNAME,DIR,FNAME,EXT);,         fnstr:=FNAME+EXT;,         While length(fnstr)<12 do insert(' ',fnstr,length(fnstr)+1);,         FDT(LZH1.Dos_DT);,         inc(totu,lzh1.ucompsize);,         inc(totc,lzh1.compsize);,         inc(fls,1);,         Case LZH1.Method[4] of {normally only 0,1 or 5},           '0' : LZHMeth:='Stored ';,           '1' : LZHMeth:='Frozen 1';,           '2' : LZHMeth:='Frozen 2';,           '3' : LZHMeth:='Frozen 3';,           '4' : LZHMeth:='Frozen 4';,           '5' : LZHMeth:='Frozen 5';,         else LZHMeth:=' Unknown';,         end;,         LZHString:=Fnstr+' '+ord_to_str(LZH1.UCompsize,8)+' '+,                    ord_to_str(LZH1.Compsize,8)+' '+lzhmeth+' ',                    +DATE+' '+TIME;,         Writeln(LZHString);,           eindigt;      ,   Ltd (C -, fsize + lzh1. Hsize + 2),     tot intrekking,  ;   gesloten (f);  ,   Writeln (en' --------------- --------------- -------------- en',     +' - en');,,     Writeln (ord_to_str (FLS, 5) +' de documentatie en de' + ord_to_str (voedsel, 8) +' en',     + ord_to_str (toTc, 8);} {, een einde te maken aan de do_lzh begon    ;,,,     clrscr; do_lzh (en', of wat dan ook. Lzh en'); {< - de naam}, hier is, is het voorbij.



Previous:
Next Page: