Main Page   Modules   Data Structures   File List   Data Fields   Globals  

Archive operations

Main wrapper functions for primary library functions. More...

Data Structures

struct  dar_archive
 Incomplete struct for use as an archive object pointer. More...

struct  dar_sup_exception
 Container for exceptions that occur during operations. More...

struct  dar_sup_flags
 A collection of flags toogling various types of operations. More...

struct  dar_sup_libfeature
 Used to hold results when querying for available library features. More...

struct  dar_sup_libversion
 Used to assist runtime version verification during library initialization. More...

struct  dar_sup_spec
 A collection of options regarding archive location and contents. More...

struct  dar_sup_storage
 A collection of options regarding archive storage options. More...


Library initialization

Calling dar_op_library_init_macro is the easiest way to verify and initialize the library, but care must be taken to free the returned memory.

Initialization may be performed manually as well.

#define DAR_LIBRARY_INIT_MACRO(ref)
 Convenience macro for library initialization.


Functions

NAMESPACE_LIBDAR_START void dar_sup_libversion_destroy (dar_sup_libversion *ref)
 Frees any memory allocated for the members of the struct.

bool dar_op_library_init (dar_sup_libversion *inout)
 Initializes library and performs version verification.

void dar_sup_libfeature_destroy (dar_sup_libfeature *ref)
 Frees any memory allocated for the members of the struct.

void dar_op_libfeature_query (dar_sup_libfeature *ref)
 Provides complete information regarding the compiled options of the backing dar library.

void dar_archive_destroy (dar_archive *ref)
 Frees memory used by dar_archive object.

bool dar_sup_spec_defaults (dar_sup_spec *ref)
 Initializes a dar_sup_spec struct with default values.

void dar_sup_spec_destroy (dar_sup_spec *ref)
 Frees any memory allocated for the members of the struct.

bool dar_sup_storage_defaults (dar_sup_storage *ref)
 Initializes a dar_sup_storage struct with default values.

void dar_sup_storage_destroy (dar_sup_storage *ref)
 Frees any memory allocated for the members of the struct.

void dar_sup_flags_defaults (dar_sup_flags *ref)
 Initializes a dar_sup_flags struct with default values.

void dar_sup_exception_destroy (dar_sup_exception *ref)
 Frees any memory allocated for the members of the struct.

dar_archivedar_op_archive_create (dar_user_interaction_struct dialog, dar_archive *ref_archive, dar_sup_spec archive_options, dar_sup_storage format_options, dar_sup_flags option_flags, dar_statistics *operation_stats, dar_sup_exception *exception)
 Create a new archive.

bool dar_op_archive_get_children_of (dar_user_interaction_struct dialog, dar_archive *archive, char *directory, dar_sup_exception *exception)
 Obtain a listing of any children of a given path of a file in an archive.

dar_archivedar_op_archive_isolate (dar_user_interaction_struct dialog, dar_archive *ref_archive, dar_sup_spec archive_options, dar_sup_storage format_options, dar_sup_flags option_flags, dar_sup_exception *exception)
 Isolates a catalog from a given archive and places it in a new empty archive.

bool dar_op_archive_diff (dar_user_interaction_struct dialog, dar_archive *archive, dar_sup_spec archive_options, dar_sup_flags option_flags, dar_statistics *operation_stats, dar_sup_exception *exception)
 Compares an archive with the filesystem.

bool dar_op_archive_extract (dar_user_interaction_struct dialog, dar_archive *archive, dar_sup_spec archive_options, dar_sup_storage format_options, dar_sup_flags option_flags, dar_statistics *operation_stats, dar_sup_exception *exception)
 Extracts data from an archive, restoring it onto the file system.

bool dar_op_archive_list (dar_user_interaction_struct dialog, dar_archive *archive, dar_sup_spec archive_options, dar_sup_flags option_flags, dar_sup_exception *exception)
 Lists files in the archive according to a selection filter.

bool dar_op_archive_test (dar_user_interaction_struct dialog, dar_archive *archive, dar_sup_spec archive_options, dar_statistics *operation_stats, dar_sup_exception *exception)
 Tests an archive's integrity.

bool dar_op_archive_close (dar_archive *archive, dar_sup_exception *exception)
 Closes an open archive.

dar_archivedar_op_archive_open (dar_user_interaction_struct dialog, dar_sup_spec archive_options, dar_sup_storage format_options, dar_sup_exception *exception)
 Opens an archive, reading its catalog into memory.


Detailed Description

Main wrapper functions for primary library functions.


Define Documentation

#define DAR_LIBRARY_INIT_MACRO ref   
 

Value:

ref.major = LIBDARC_MAJOR_VERSION; \
ref.minor = LIBDARC_MINOR_VERSION; \
ref.micro = LIBDARC_MICRO_VERSION; \
dar_op_library_init(&ref)
Convenience macro for library initialization.

When using dar_op_library_init directly the libversion struct must be initialized with the binding version. This macro automatically inserts the values found in the header file.

An uninitialized dar_sup_libversion variable. The structure will be modified as in dar_op_library_init and must be passed to dar_sup_libversion_destroy when finished to free any allocated memory.

Definition at line 368 of file libdarc.h.


Function Documentation

bool dar_op_archive_close dar_archive   archive,
dar_sup_exception   exception
 

Closes an open archive.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               
        Subtree mask                 

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         
        Encryption block size        
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Returns true if archive closed without error; otherwise false. If the operation failed, the returned exception should be consulted.

Definition at line 1029 of file libdarc.cpp.

References LIBDAR_NOEXCEPT, and LIBDARC_EXCEPTION.

dar_archive* dar_op_archive_create dar_user_interaction_struct    dialog,
dar_archive   ref_archive,
dar_sup_spec    archive_options,
dar_sup_storage    format_options,
dar_sup_flags    option_flags,
dar_statistics   operation_stats,
dar_sup_exception   exception
 

Create a new archive.

The library will archive files from the given file system paths into one or more slice files. The slices, inserted in the indicated directory, will be named BASENAME + SLICE NUMBER + FILE EXTENSION. A reference archive may be provided for differential or incremental backups.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    X
        Archive path                 X
        Archive name                 X
        Archive extension            X
        Input pipe                   
        Output pipe                  
        Selection mask               X
        Subtree mask                 X

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        X
        Compression level            X
        Compression mask             X
        Compression min. size        X
        Encryption algorithm         X
        Encryption block size        X        
        Encryption passphrase        X
        File size                    X
        First file size              X
        Slice excecute command       X
        Hourshift                    X

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              X
        Warn overwrite               X
        Slice pause                  X
        Create empty stubs           X
        System EA                    X
        User EA                      X
        No dump                      X
        Ignore owner                 X
        Test run                     X
        Alter atime                  X
        Same file system             X
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Pointer to newly created archive object. Tests should not be performed with this new object. The archive should be freshly reread from the file system.
Note:
Statistics returned by this function:
  • treated : The total number of files encountered.
  • hard_links : Hard linked inodes saved.
  • skipped : Files not changed (for differential backups).
  • ignored : Files excluded by filters.
  • error : Files not read because of a filesystem error.
  • deleted : Files recorded as deleted (since last backup).

Definition at line 467 of file libdarc.cpp.

References dar_sup_flags::allow_overwrite, dar_sup_flags::alter_atime, dar_sup_spec::arc_ext, dar_sup_spec::arc_name, dar_sup_spec::arc_path, dar_sup_storage::compress_algo, dar_sup_storage::compress_level, dar_sup_storage::compress_mask, dar_sup_storage::compress_min_size, dar_sup_flags::create_empty_stubs, dar_sup_storage::crypto_algo, dar_sup_storage::crypto_pass, dar_sup_storage::crypto_size, dar_user_interaction_struct_is_valid(), dar_sup_flags::ea_system, dar_sup_flags::ea_user, dar_sup_storage::file_size, dar_sup_storage::first_file_size, dar_sup_storage::hourshift, dar_sup_flags::ignore_owner, LIBDAR_ELIBCALL, LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_flags::no_dump, dar_sup_spec::root_path, dar_sup_flags::same_fs, dar_sup_spec::selection, dar_sup_storage::slice_execute, dar_sup_flags::slice_pause, dar_sup_spec::subtree, dar_sup_flags::test_run, dar_user_interaction_struct::verbose, and dar_sup_flags::warn_overwrite.

bool dar_op_archive_diff dar_user_interaction_struct    dialog,
dar_archive   archive,
dar_sup_spec    archive_options,
dar_sup_flags    option_flags,
dar_statistics   operation_stats,
dar_sup_exception   exception
 

Compares an archive with the filesystem.

FIXME: (1) how are differences indicated in callbacks? (2) how exactly are statistics returned?

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    X
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               X
        Subtree mask                 X

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         
        Encryption block size        
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    X
        User EA                      X
        No dump                      
        Ignore owner                 X
        Test run                     
        Alter atime                  X
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Returns true if there are any differences; otherwise false. Statistics will be returns in the operation_stats parameter and differences will be listed in the warning or listing callback.
Note:
Statistics returned by this function:
  • treated : The total number of files encountered.
  • ignored : Files left uncompared because of filters.
  • error : Files which differed or could not be read.

Definition at line 753 of file libdarc.cpp.

References dar_sup_flags::alter_atime, dar_user_interaction_struct_is_valid(), dar_sup_flags::ea_system, dar_sup_flags::ea_user, dar_sup_flags::ignore_owner, LIBDAR_ELIBCALL, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_spec::root_path, dar_sup_spec::selection, dar_sup_spec::subtree, and dar_user_interaction_struct::verbose.

bool dar_op_archive_extract dar_user_interaction_struct    dialog,
dar_archive   archive,
dar_sup_spec    archive_options,
dar_sup_storage    format_options,
dar_sup_flags    option_flags,
dar_statistics   operation_stats,
dar_sup_exception   exception
 

Extracts data from an archive, restoring it onto the file system.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    X
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               X
        Subtree mask                 X

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         
        Encryption block size        
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    X

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              X
        Warn overwrite               X
        Slice pause                  
        Create empty stubs           
        System EA                    X
        User EA                      X
        No dump                      
        Ignore owner                 
        Test run                     X
        Alter atime                  
        Same file system             
        Delete marked                X
        Restore flat                 X
        Warn rem. non-matching       X
        Only restore more recent     X
        Tar format listing           
        Filter unsaved               

Returns:
Returns true if the operation performed without error; otherwise false. If the operation failed, the returned exception should be consulted.
Note:
Statistics returned by this function:
  • treated : The total number of files encountered.
  • skipped : Files not saved in the archive (marked as deleted or as catalog references).
  • ignored : Files not extracted because of filters.
  • target_changed : Files not extracted because existing file on the file system has a more recent modification date.
  • error : Files not extracted because of file system errors.
  • deleted : Files deleted from the file system.

Definition at line 828 of file libdarc.cpp.

References dar_sup_flags::allow_overwrite, dar_user_interaction_struct_is_valid(), dar_sup_flags::delete_marked, dar_sup_flags::ea_system, dar_sup_flags::ea_user, dar_sup_storage::hourshift, dar_sup_flags::ignore_owner, LIBDAR_ELIBCALL, LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_flags::only_more_recent, dar_sup_flags::restore_flat, dar_sup_spec::root_path, dar_sup_spec::selection, dar_sup_spec::subtree, dar_sup_flags::test_run, dar_user_interaction_struct::verbose, dar_sup_flags::warn_overwrite, and dar_sup_flags::warn_remove_no_match.

bool dar_op_archive_get_children_of dar_user_interaction_struct    dialog,
dar_archive   archive,
char *    directory,
dar_sup_exception   exception
 

Obtain a listing of any children of a given path of a file in an archive.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               
        Subtree mask                 

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm  
        Encryption block size                  
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Returns true if any children have been found. The actual files are returned using the listing callback. If that callback is not defined, no listing will occur.

Definition at line 613 of file libdarc.cpp.

References dar_user_interaction_struct_is_valid(), LIBDAR_ELIBCALL, LIBDAR_NOEXCEPT, and LIBDARC_EXCEPTION.

dar_archive* dar_op_archive_isolate dar_user_interaction_struct    dialog,
dar_archive   ref_archive,
dar_sup_spec    archive_options,
dar_sup_storage    format_options,
dar_sup_flags    option_flags,
dar_sup_exception   exception
 

Isolates a catalog from a given archive and places it in a new empty archive.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 X
        Archive name                 X
        Archive extension            X
        Input pipe                   
        Output pipe                  
        Selection mask               
        Subtree mask                 

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        X
        Compression level            X
        Compression mask             
        Compression min. size        
        Encryption algorithm         X
        Encryption block size        X
        Encryption passphrase        X
        File size                    X
        First file size              X
        Slice excecute command       X
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              X
        Warn overwrite               X
        Slice pause                  X
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     X
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Pointer to a newly created archive object. The new archive contains a catalog but no actual file data. This archive can be used as a reference archive as if it were the original archive.

Definition at line 653 of file libdarc.cpp.

References dar_sup_flags::allow_overwrite, dar_sup_spec::arc_ext, dar_sup_spec::arc_name, dar_sup_spec::arc_path, dar_sup_storage::compress_algo, dar_sup_storage::compress_level, dar_sup_flags::create_empty_stubs, dar_sup_storage::crypto_algo, dar_sup_storage::crypto_pass, dar_sup_storage::crypto_size, dar_user_interaction_struct_is_valid(), dar_sup_storage::file_size, dar_sup_storage::first_file_size, LIBDAR_ELIBCALL, LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_storage::slice_execute, dar_sup_flags::slice_pause, dar_sup_flags::test_run, and dar_user_interaction_struct::verbose.

bool dar_op_archive_list dar_user_interaction_struct    dialog,
dar_archive   archive,
dar_sup_spec    archive_options,
dar_sup_flags    option_flags,
dar_sup_exception   exception
 

Lists files in the archive according to a selection filter.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               X
        Subtree mask                 

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         
        Encryption block size        
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           X
        Filter unsaved               X

Returns:
Returns true if the operation performed without error; otherwise false. If the operation failed, the returned exception should be consulted. Files will be listed using the warning or listing callback.

Definition at line 930 of file libdarc.cpp.

References dar_user_interaction_struct_is_valid(), dar_sup_flags::filter_unsaved, LIBDAR_ELIBCALL, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_spec::selection, dar_sup_flags::tar_format, and dar_user_interaction_struct::verbose.

dar_archive* dar_op_archive_open dar_user_interaction_struct    dialog,
dar_sup_spec    archive_options,
dar_sup_storage    format_options,
dar_sup_exception   exception
 

Opens an archive, reading its catalog into memory.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 X
        Archive name                 X
        Archive extension            X
        Input pipe                   X
        Output pipe                  X
        Selection mask               
        Subtree mask                 

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         X
        Encryption block size        X
        Encryption passphrase        X
        File size                    
        First file size              
        Slice excecute command       X
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Pointer to the read in archive object.

Definition at line 1055 of file libdarc.cpp.

References dar_sup_spec::arc_ext, dar_sup_spec::arc_name, dar_sup_spec::arc_path, dar_sup_storage::crypto_algo, dar_sup_storage::crypto_pass, dar_sup_storage::crypto_size, dar_user_interaction_struct_is_valid(), dar_sup_spec::input_pipe, LIBDAR_ELIBCALL, LIBDAR_EMEMORY, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_spec::output_pipe, dar_sup_storage::slice_execute, and dar_user_interaction_struct::verbose.

Referenced by dar_drc_open_reference().

bool dar_op_archive_test dar_user_interaction_struct    dialog,
dar_archive   archive,
dar_sup_spec    archive_options,
dar_statistics   operation_stats,
dar_sup_exception   exception
 

Tests an archive's integrity.

This function may not be called with an archive object recieved directly from the isolation or creation functions. Because those objects will not reflect any actual on disk write errors they must be destroyed after creation. The archive must then be freshly read in from disk and then tested.

Field usage:

        Field name                  Used

ARCHIVE OPTIONS (dar_sup_spec)
        Root path                    
        Archive path                 
        Archive name                 
        Archive extension            
        Input pipe                   
        Output pipe                  
        Selection mask               X
        Subtree mask                 X

FORMAT OPTIONS (dar_sup_storage)
        Compression algorithm        
        Compression level            
        Compression mask             
        Compression min. size        
        Encryption algorithm         
        Encryption block size        
        Encryption passphrase        
        File size                    
        First file size              
        Slice excecute command       
        Hourshift                    

OPTION FLAGS (dar_sup_flags)
        Allow overwrite              
        Warn overwrite               
        Slice pause                  
        Create empty stubs           
        System EA                    
        User EA                      
        No dump                      
        Ignore owner                 
        Test run                     
        Alter atime                  
        Same file system             
        Delete marked                
        Restore flat                 
        Warn rem. non-matching       
        Only restore more recent     
        Tar format listing           
        Filter unsaved               

Returns:
Returns true if all tested files are without error; otherwise false. If the operation failed, the returned exception should be consulted.
Note:
Statistics returned by this function:
  • treated : The total number of files encountered.
  • skipped : Files older that the one on the file system.
  • error : Files in the archive which contain an error.

Definition at line 978 of file libdarc.cpp.

References dar_user_interaction_struct_is_valid(), LIBDAR_ELIBCALL, LIBDAR_NOEXCEPT, LIBDARC_EXCEPTION, dar_sup_spec::selection, dar_sup_spec::subtree, and dar_user_interaction_struct::verbose.

void dar_op_libfeature_query dar_sup_libfeature   ref
 

Provides complete information regarding the compiled options of the backing dar library.

This information can be used to filter unsupported calls, etc. When an operation is performed using an unsupported option (e.g. selected gzip compression when the gzip library is not available) said operation will fail, returning a LIBDAR_ECOMPILATION error code.

Any memory allocated to the structure must be cleared by passing it to dar_sup_libfeature_destroy.

Definition at line 124 of file libdarc.cpp.

References dar_sup_libfeature::ea, dar_sup_libfeature::largefile, dar_sup_libfeature::libbz2, dar_sup_libfeature::libcrypto, dar_sup_libfeature::libz, dar_sup_libfeature::nodump, dar_sup_libfeature::os_bits, dar_sup_libfeature::special_alloc, and dar_sup_libfeature::thread_safe.

bool dar_op_library_init dar_sup_libversion   inout
 

Initializes library and performs version verification.

Binding user must provide compile time version as input. The input version parameter will be replaced with the actual runtime binding version. If the linked shared library is an invalid version, false will be returned and the exception data will be placed in the version parameter.

While the API/ABI breakage policy of the C binding the same as that of libdar the use of this function (or its automatic counterpart) is preferred. This provides an extra level of protection in case the policy changes.

Parameters:
inout  When called, compile time version must be input. On return, the runtime version will be output. Any exceptions will also be specified in the structure.
Returns:
False if an initialization or version verification error occured; otherwise true.

Definition at line 60 of file libdarc.cpp.

References dar_sup_libversion::except_msg, dar_sup_libversion::exception, LIBDAR_ELIBCALL, LIBDAR_NOEXCEPT, dar_sup_libversion::major, dar_sup_libversion::micro, and dar_sup_libversion::minor.

void dar_sup_exception_destroy dar_sup_exception   ref
 

Frees any memory allocated for the members of the struct.

Parameters:
ref  Exception container to destroy.

Definition at line 444 of file libdarc.cpp.

References dar_sup_exception::message.

void dar_sup_flags_defaults dar_sup_flags   ref
 

Initializes a dar_sup_flags struct with default values.

Parameters:
ref  Option collections to initialize.

Definition at line 422 of file libdarc.cpp.

References dar_sup_flags::allow_overwrite, dar_sup_flags::alter_atime, dar_sup_flags::create_empty_stubs, dar_sup_flags::delete_marked, dar_sup_flags::ea_system, dar_sup_flags::ea_user, dar_sup_flags::filter_unsaved, dar_sup_flags::ignore_owner, dar_sup_flags::no_dump, dar_sup_flags::only_more_recent, dar_sup_flags::restore_flat, dar_sup_flags::same_fs, dar_sup_flags::slice_pause, dar_sup_flags::tar_format, dar_sup_flags::test_run, dar_sup_flags::warn_overwrite, and dar_sup_flags::warn_remove_no_match.

void dar_sup_libfeature_destroy dar_sup_libfeature   ref
 

Frees any memory allocated for the members of the struct.

Parameters:
ref  Feature listing to destroy.

Definition at line 118 of file libdarc.cpp.

NAMESPACE_LIBDAR_START void dar_sup_libversion_destroy dar_sup_libversion   ref
 

Frees any memory allocated for the members of the struct.

Parameters:
ref  Library version struct to destroy.

Definition at line 50 of file libdarc.cpp.

References dar_sup_libversion::except_msg.

bool dar_sup_spec_defaults dar_sup_spec   ref
 

Initializes a dar_sup_spec struct with default values.

Because there are currently no default values for this struct, this function only initializes members as zero or NULL.

Parameters:
ref  Option collection to initialize.
Returns:
False if memory error was encountered. Caller should terminate or pass the struct to the destroy function to free any allocated members.

Definition at line 162 of file libdarc.cpp.

References dar_sup_spec::arc_ext, dar_sup_spec::arc_name, dar_sup_spec::arc_path, dar_sup_spec::input_pipe, dar_sup_spec::output_pipe, dar_sup_spec::root_path, dar_sup_spec::selection, and dar_sup_spec::subtree.

void dar_sup_spec_destroy dar_sup_spec   ref
 

Frees any memory allocated for the members of the struct.

Parameters:
ref  Option collection to destroy.

Definition at line 176 of file libdarc.cpp.

References dar_sup_spec::arc_ext, dar_sup_spec::arc_name, dar_sup_spec::arc_path, dar_mask_destroy(), dar_sup_spec::input_pipe, dar_sup_spec::output_pipe, dar_sup_spec::root_path, dar_sup_spec::selection, and dar_sup_spec::subtree.

Referenced by dar_drc_destroy().

bool dar_sup_storage_defaults dar_sup_storage   ref
 

Initializes a dar_sup_storage struct with default values.

All pointers will be set to null. If not reassigned, they will be replaced with the default values during an archive operation.

Parameters:
ref  Option collection to initialize.
Returns:
False if memory error was encountered. Caller should terminate or pass the struct to the destroy function to free any allocated members.

Definition at line 234 of file libdarc.cpp.

References dar_sup_storage::compress_algo, dar_sup_storage::compress_level, dar_sup_storage::compress_mask, dar_sup_storage::compress_min_size, dar_sup_storage::crypto_algo, dar_sup_storage::crypto_pass, dar_sup_storage::crypto_size, dar_compression_none, dar_crypto_none, dar_sup_storage::file_size, dar_sup_storage::first_file_size, dar_sup_storage::hourshift, and dar_sup_storage::slice_execute.

void dar_sup_storage_destroy dar_sup_storage   ref
 

Frees any memory allocated for the members of the struct.

Parameters:
ref  Option collection to destroy.

Definition at line 396 of file libdarc.cpp.

References dar_sup_storage::compress_mask, dar_sup_storage::compress_min_size, dar_sup_storage::crypto_pass, dar_infinint_destroy(), dar_mask_destroy(), dar_sup_storage::file_size, dar_sup_storage::first_file_size, dar_sup_storage::hourshift, and dar_sup_storage::slice_execute.

Referenced by dar_drc_destroy().