You are here

mkZiplib 1.0

admin의 아바타

홈페이지 : http://mkextensions.sourceforge.net/

mkZiplib는 Zlib 1.1.3과 Minizip 0.15를 토대로 Tcl에서 사용하기 쉽게 감싸준 확장패키지입니다.
zlib는 zip이나 gz 포맷의 데이타 압축및 해제를 해주는 라이브러리입니다.

  % set sComp [deflate -level 9 "We all live in a yellow submarine, yellow submarine, yellow submarine..."]
  (...Repetitive patterns are good for compression...)
  % inflate $sComp
  We all live in a yellow submarine, yellow submarine, yellow submarine...
  % set hGz [gz open test.gz w]
  4457920
  % gz write $hGz "We all live in a yellow submarine, yellow submarine, yellow submarine...n"
  72
  % gz close $hGz
  %
  % set hGz [gz open test.txt.gz]
  4457920
  % gz gets $hGz
  We all live in a yellow submarine, yellow submarine, yellow submarine...
  % gz close $hGz
  % set hZip [zip open test.zip w]
  10289776
  % zip set $hZip file1.txt -level 9 -comment "File 1" -time [clock seconds]
  % zip write $hZip "This is the contents of file 1"
  % zip set $hZip file2.txt -level 9 -comment "File 2" -time [clock seconds]
  % zip write $hZip "This is the contents of file 2"
  % zip comment $hZip "My first zip file"
  %
  % set hZip [zip open test.zip]
  10244344
  % zip comment $hZip
  My first zip file
  % zip files $hZip
  file1.txt file2.txt
  % zip info $hZip file1.txt
  988336176 30 30 0 {File 1}
  % zip info $hZip file1.txt
  988336234 30 30 0 {File 2}
  % zip set $hZip file1.txt
  % zip read $hZip
  This is the contents of file1
  % zip set $hZip file2.txt
  % zip read $hZip
  This is the contents of file2
  % zip close $hZip
  %
  • mkTables10.htm: 메뉴얼
  • mkZiplib10.zip
  • 첨부 파일파일 크기
    HTML icon mkTables10.htm9.86 KB
    Package icon mkZiplib10.zip95.41 KB