MyCaffe  1.12.2.41
Deep learning software for Windows C# programmers.
MyCaffe.basecode.TarFile Class Reference

The TarFile functions are used to expand tar files. More...

Public Member Functions

 TarFile ()
 The constructor. More...
 

Static Public Member Functions

static int ExtractTar (string strFileName, string strOutputDir, CancelEvent evtCancel=null, Log log=null, int nExpectedTotal=0, int nIdx=0)
 Extract a Tar (*.tar) file to a specified output directory. More...
 
static int ExtractTar (Stream stream, string strOutputDir, CancelEvent evtCancel=null, Log log=null, int nExpectedTotal=0, int nIdx=0)
 Extract Tar data from a stream to a specified output directory. More...
 
static void ExtractTarGz (string strFileName, string strOutputDir)
 Extract a Gz zipped file to the output directory. More...
 
static void ExtractTarGz (Stream stream, string strOutputDir)
 Extract a Gz stream to the output directory. More...
 

Detailed Description

The TarFile functions are used to expand tar files.

See also
Decompress tar files using C#, StackOverflow, 2012
GitHub: ForeverZer0/ExtractTarGz ForeverZero0

Definition at line 19 of file TarFile.cs.

Constructor & Destructor Documentation

◆ TarFile()

MyCaffe.basecode.TarFile.TarFile ( )

The constructor.

Definition at line 24 of file TarFile.cs.

Member Function Documentation

◆ ExtractTar() [1/2]

static int MyCaffe.basecode.TarFile.ExtractTar ( Stream  stream,
string  strOutputDir,
CancelEvent  evtCancel = null,
Log  log = null,
int  nExpectedTotal = 0,
int  nIdx = 0 
)
static

Extract Tar data from a stream to a specified output directory.

Parameters
streamSpecifies the stream containing the Tar data to extract.
strOutputDirSpecifies the output directory.
evtCancelOptionally, specifies the cancel event used to cancel the extraction (default = null).
logOptionally, specifies the Log used to output status of the extraction (default = null).
nExpectedTotalOptionally, specifies the expected total number of files (default = 0).
nIdxOptionally, specifies an item index (default = 0).
Returns
Upon a successful extraction, the number of files extracted offset by the index is returned, or 0 on abort.

Definition at line 56 of file TarFile.cs.

◆ ExtractTar() [2/2]

static int MyCaffe.basecode.TarFile.ExtractTar ( string  strFileName,
string  strOutputDir,
CancelEvent  evtCancel = null,
Log  log = null,
int  nExpectedTotal = 0,
int  nIdx = 0 
)
static

Extract a Tar (*.tar) file to a specified output directory.

Parameters
strFileNameSpecifies the name of the .tar file to extract.
strOutputDirSpecifies the output directory.
evtCancelOptionally, specifies the cancel event used to cancel the extraction (default = null).
logOptionally, specifies the Log used to output status of the extraction (default = null).
nExpectedTotalOptionally, specifies the expected total number of files (default = 0).
nIdxOptionally, specifies an item index (default = 0).
Returns
Upon a successful extraction, the number of files extracted offset by the index is returned, or 0 on abort.

Definition at line 38 of file TarFile.cs.

◆ ExtractTarGz() [1/2]

static void MyCaffe.basecode.TarFile.ExtractTarGz ( Stream  stream,
string  strOutputDir 
)
static

Extract a Gz stream to the output directory.

Parameters
streamSpecifies the Gz stream.
strOutputDirSpecifies the output directory.

Definition at line 157 of file TarFile.cs.

◆ ExtractTarGz() [2/2]

static void MyCaffe.basecode.TarFile.ExtractTarGz ( string  strFileName,
string  strOutputDir 
)
static

Extract a Gz zipped file to the output directory.

Parameters
strFileNameSpecifize the .gz file to extract.
strOutputDirSpecifies the output directory.

Definition at line 144 of file TarFile.cs.


The documentation for this class was generated from the following file: