| Disk ARchive 2.5.10 Full featured and portable backup and archiving tool

- Main Page
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
libdar::archive_options_read Class Reference
API

class holding optional parameters used to read an existing archive More...

`#include <archive_options.hpp>`

Inherits libdar::on_pool.

## Public Member Functions
| archive_options_read ()
| build an object and set options to their default values
| archive_options_read (const archive_options_read &ref)
| the copy constructor, assignment operator and destructor
const archive_options_read & | operator= (const archive_options_read &ref)
void | clear ()
| reset all the options to their default values
void | set_crypto_algo (crypto_algo val)
void | set_crypto_pass (const secu_string &pass)
| defines the password or passphrase to decrypt (unused if encryption is not set)
void | set_crypto_size (U_32 crypto_size)
| the encryption block size to use to decrypt
void | set_default_crypto_size ()
| set the encryption block size to the default value
void | set_input_pipe (const std::string &input_pipe)
| set the name of the input pipe to read data from (when basename is set to "-") More...
void | set_output_pipe (const std::string &output_pipe)
| set the name of the output pipe to send orders to (when basenale is set to "-") More...
void | set_execute (const std::string &execute)
| set the command to execute before reading each slice (empty string for no script) More...
void | set_info_details (bool info_details)
| defines whether the user needs detailed output of the operation
void | set_lax (bool val)
| defines whether any archive coherence error, system error or media error lead to the abortion of the operation More...
void | set_sequential_read (bool val)
| defines whether to try reading the archive sequentially (ala tar) or using the final catalogue More...
void | set_slice_min_digits (infinint val)
| defines the minimum digit a slice must have concerning its number, zeros will be prepended as much as necessary to respect this
void | set_entrepot (const entrepot &entr)
| defines the protocol to use to retrieve slices
void | set_ignore_signature_check_failure (bool val)
| whether to warn (true) or ignore (false) signature failure (default is true)
void | set_multi_threaded (bool val)
| whether libdar is allowed to create several thread to work possilbiy faster on multicore CPU (need libthreadar to be effective)
void | set_external_catalogue (const path &ref_chem, const std::string &ref_basename)
| defines whether or not to use the catalogue from an extracted catalogue (instead of the one embedded in the archive) and which one to use
void | unset_external_catalogue ()
| clear any reference to an external catalogue
void | set_ref_crypto_algo (crypto_algo ref_crypto)
| defines the crypto algo for the reference catalogue
void | set_ref_crypto_pass (const secu_string &ref_pass)
| defines the pass for the reference catalogue
void | set_ref_crypto_size (U_32 ref_crypto_size)
| defines the crypto size for the reference catalogue
void | set_ref_execute (const std::string &ref_execute)
| set the command to execute before reading each slice of the reference catalogue More...
void | set_ref_slice_min_digits (infinint val)
| defines the minim digit for slice number of the archive of reference (where the external catalogue is read from)
void | set_ref_entrepot (const entrepot &entr)
| defines the protocol to use to retrieve slices of the reference archive (where the external catalogue resides)
crypto_algo | get_crypto_algo () const
const secu_string & | get_crypto_pass () const
U_32 | get_crypto_size () const
const std::string & | get_input_pipe () const
const std::string & | get_output_pipe () const
const std::string & | get_execute () const
bool | get_info_details () const
bool | get_lax () const
bool | get_sequential_read () const
infinint | get_slice_min_digits () const
const entrepot & | get_entrepot () const
bool | get_ignore_signature_check_failure () const
bool | get_multi_threaded () const
bool | is_external_catalogue_set () const
const path & | get_ref_path () const
const std::string & | get_ref_basename () const
crypto_algo | get_ref_crypto_algo () const
const secu_string & | get_ref_crypto_pass () const
U_32 | get_ref_crypto_size () const
const std::string & | get_ref_execute () const
infinint | get_ref_slice_min_digits () const
const entrepot & | get_ref_entrepot () const
Public Member Functions inherited from libdar::on_pool
void * | operator new (size_t n_byte)
void * | operator new (size_t n_byte, const std::nothrow_t &nothrow_value)
void * | operator new[] (size_t n_byte)
void * | operator new[] (size_t n_byte, const std::nothrow_t &nothrow_value)
void * | operator new (size_t n_byte, memory_pool *p)
void * | operator new[] (size_t n_byte, memory_pool *p)
void | operator delete (void *ptr, memory_pool *p)
| this operator is called by the compiler if an exception is throw from the constructor of the allocated object
void | operator delete[] (void *ptr, memory_pool *p)
| this operator is called by the compiler if an exception is throw from the constructor of the allocated objects
void | operator delete (void *ptr)
| this is the usual delete operator, modified to handle allocated objects allocated on a memory pool or not
void | operator delete[] (void *ptr)
| this is the usual delete[] operator, modified to handle allocated objects allocated on a memory pool or not

## Additional Inherited Members
Protected Member Functions inherited from libdar::on_pool
memory_pool * | get_pool () const
template<class T >
void | meta_new (T *&ptr, size_t num)
template<class T >
void | meta_delete (T *ptr)

## Detailed Description

class holding optional parameters used to read an existing archive

Definition at line 59 of file archive_options.hpp.

## Member Function Documentation

void libdar::archive_options_read::set_crypto_algo | ( | crypto_algo | val | ) |
| inline

defines the the crypto cypher to use to read the archive (default is crypto_none)

Note
  since release 2.5.0 you may and should provide crypto_none in any case (the default value) for libdar uses the algorithm stored in the archive. However you way override this (in case of corruption for example) by explicitely specifying a crypto algorithm in that case the value of the crypto algorithm stored in the archive is ignored and the algorithm used to decipher is the one specified here.

Definition at line 89 of file archive_options.hpp.

void libdar::archive_options_read::set_execute | ( | const std::string & | execute | ) |
| inline

set the command to execute before reading each slice (empty string for no script)

several macros are available:

- %n : the slice number to be read
- %b : the archive basename
- %p : the slices path
- %e : the archive extension (usually "dar")
- %%% : substitued by %%

Definition at line 121 of file archive_options.hpp.

void libdar::archive_options_read::set_input_pipe | ( | const std::string & | input_pipe | ) |
| inline

set the name of the input pipe to read data from (when basename is set to "-")

if input_pipe is set to "" (empty string) the information from dar_slave are expected in standard input else the given string

Definition at line 104 of file archive_options.hpp.

void libdar::archive_options_read::set_lax | ( | bool | val | ) |
| inline

defines whether any archive coherence error, system error or media error lead to the abortion of the operation

lax mode is false by default. setting it to true, may allow more data to be restored, but may lead the user to get corrupted data the user will be warned and asked upon what to do if such case arrives.

Definition at line 131 of file archive_options.hpp.

void libdar::archive_options_read::set_output_pipe | ( | const std::string & | output_pipe | ) |
| inline

set the name of the output pipe to send orders to (when basenale is set to "-")

if output_pipe is set to "" the orders sent to dar_slave will exit by the standard output else the given string must be the path to a named pipe which will relay the orders to dar_slave

Definition at line 110 of file archive_options.hpp.

void libdar::archive_options_read::set_ref_execute | ( | const std::string & | ref_execute | ) |
| inline

set the command to execute before reading each slice of the reference catalogue

several macros are available:

- %n : the slice number to be read
- %b : the archive basename
- %p : the slices path
- %e : the archive extension (usually "dar")
- %%% : substitued by %%

Definition at line 179 of file archive_options.hpp.

void libdar::archive_options_read::set_sequential_read | ( | bool | val | ) |
| inline

defines whether to try reading the archive sequentially (ala tar) or using the final catalogue

the sequential reading must not has been disabled at creation time and the archive must be of minimum format "08" for the operation not to fail

Definition at line 137 of file archive_options.hpp.

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

- archive_options.hpp