메소드 | 설명 | |
---|---|---|
CookZipEntryName ( string name, string stripPrefix, bool relativePath ) : string |
'Cook' a name making it acceptable as a zip entry name.
|
|
Main ( string args ) : void |
Entry point for program, creates archiver and runs it
|
메소드 | 설명 | |
---|---|---|
Add ( |
||
AddFile ( string fileName ) : void |
Add file to archive
|
|
AddFileSeekableOutput ( string file, string entryPath ) : void |
Add a file were the output is seekable
|
|
AddFolder ( string folderName ) : void |
Add an entry for a folder or directory
|
|
CompressFolder ( string basePath, bool recursiveSearch, string searchPattern ) : int |
Compress contents of folder
|
|
CookZipEntryName ( string name ) : string |
Make string into something acceptable as an entry name
|
|
Create ( |
Create archives based on specifications passed and internal state
|
|
DecompressFile ( string fileName, string targetDir ) : bool |
Decompress a file
|
|
Delete ( |
Delete entries from an archive
|
|
Execute ( string args ) : void |
Parse command line arguments and 'execute' them.
|
|
Extract ( |
Extract archives based on user input Allows simple wildcards to specify multiple archives
|
|
ExtractDirectory ( |
||
ExtractFile ( |
||
GetBuffer ( ) : byte[] | ||
GetCompressionRatio ( long packedSize, long unpackedSize ) : int |
Calculate compression ratio as a percentage Doesnt allow for expansion (ratio > 100) as the resulting strings can get huge easily
|
|
InterpretExternalAttributes ( int operatingSystem, int attributes ) : string |
Interpret attributes based on the operating system they are from.
|
|
IsNumeric ( string rhs ) : bool |
Determine if string is numeric [0-9]+
|
|
List ( |
Execute List operation Currently only Zip files are supported
|
|
ListZip ( string fileName ) : void |
List zip file contents using stream
|
|
ListZipViaZipFile ( string fileName ) : void |
List zip file contents using ZipFile class
|
|
SetArgs ( string args ) : bool |
Parse command line arguments. This is fairly flexible without using any custom classes. Arguments and options can appear in any order and are case insensitive. Arguments for options are indicated with an '=' as in -demo=argument, sometimes the '=' can be omitted as well secretly. Grouping of single character options is supported. The actual arguments and their handling is however a grab bag of ad-hoc things and its a bit messy. Could be a bit more rigorous about how things are done. Up side is almost anything is/can be allowed
|
|
ShowEnvironment ( ) : void |
Show encoding/locale information
|
|
ShowHelp ( ) : void |
Show help on possible options and arguments
|
|
ShowVersion ( ) : void |
Display version information
|
|
Test ( |
public static CookZipEntryName ( string name, string stripPrefix, bool relativePath ) : string | ||
name | string | name to cook |
stripPrefix | string | String to remove from front of name if present |
relativePath | bool | Make names relative if |
리턴 | string |
public static Main ( string args ) : void | ||
args | string | /// Command line argument to process /// |
리턴 | void |