Loading...
Searching...
No Matches
filesystem_tools.hpp
Go to the documentation of this file.
/*********************************************************************/
// dar - disk archive - a backup/restoration program
// Copyright (C) 2002-2026 Denis Corbin
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
//
// to contact the author, see the AUTHOR file
/*********************************************************************/
#ifndef FILESYSTEM_TOOLS_HPP
#define FILESYSTEM_TOOLS_HPP
#include "../my_config.h"
extern "C"
{
} // end extern "C"
#include "infinint.hpp"
#include "generic_file.hpp"
#include "fsa_family.hpp"
#include "cat_all_entrees.hpp"
#include "crc.hpp"
#include "user_interaction.hpp"
#include "path.hpp"
#include "fichier_local.hpp"
#include <string>
namespace libdar
{
bool filesystem_tools_has_immutable(const cat_inode & arg);
void filesystem_tools_set_immutable(const std::string & target, bool val, user_interaction &ui);
void filesystem_tools_supprime(user_interaction & ui, const std::string & ref);
void filesystem_tools_widen_perm(user_interaction & dialog,
const cat_inode & ref,
const std::string & chem,
comparison_fields what_to_check);
void filesystem_tools_make_owner_perm(user_interaction & dialog,
const cat_inode & ref,
const std::string & chem,
comparison_fields what_to_check,
const fsa_scope & scope);
void filesystem_tools_make_date(const cat_inode & ref,
const std::string & chem,
comparison_fields what_to_check,
const fsa_scope & scope);
void filesystem_tools_attach_ea(const std::string &chemin,
cat_inode *ino,
const mask & ea_mask);
bool filesystem_tools_is_nodump_flag_set(user_interaction & dialog,
const path & chem, const std::string & filename,
bool info);
path *filesystem_tools_get_root_with_symlink(user_interaction & dialog,
const path & root,
bool info_details);
mode_t filesystem_tools_get_file_permission(const std::string & path);
void filesystem_tools_make_delta_patch(const std::shared_ptr<user_interaction> & dialog,
const cat_file & existing,
const std::string & existing_pathname,
const cat_file & patcher,
const path & directory,
bool hard_linked);
fichier_local *filesystem_tools_create_non_existing_file_based_on(const std::shared_ptr<user_interaction> & dialog,
std::string filename,
path where,
std::string & new_filename);
void filesystem_tools_copy_content_from_to(const std::shared_ptr<user_interaction> & dialog,
const std::string & source_path,
const std::string & destination_path,
const crc *expected_crc);
bool filesystem_tools_read_linux_birthtime(const std::string & target, datetime & val);
} // end of namespace
#endif
cat_all_entrees.hpp
include file gathering all entree found in a catalogue
libdar::cat_file
the plain file class
Definition cat_file.hpp:49
libdar::cat_inode
the root class for all cat_inode
Definition cat_inode.hpp:53
libdar::crc
pure virtual class defining interface of a CRC object
Definition crc.hpp:47
libdar::datetime
stores time information
Definition datetime.hpp:59
libdar::fichier_local
filesystem local files
Definition fichier_local.hpp:56
libdar::mask
the generic class, parent of all masks
Definition mask.hpp:62
libdar::path
the class path is here to manipulate paths in the Unix notation: using'/'
Definition path.hpp:51
libdar::user_interaction
This is a pure virtual class that is used by libdar when interaction with the user is required.
Definition user_interaction.hpp:58
crc.hpp
class crc definition, used to handle Cyclic Redundancy Checks
fichier_local.hpp
class fichier_local definition. This is a full implementation/inherited class of class fichier_global...
fsa_family.hpp
filesystem specific attributes available families and fsa_scope definition
generic_file.hpp
class generic_file is defined here as well as class fichier
libdar::comparison_fields
comparison_fields
how to consider file change during comparison and incremental backup
Definition archive_aux.hpp:53
libdar::fsa_scope
std::set< fsa_family > fsa_scope
set of fsa families
Definition fsa_family.hpp:70
libdar::filesystem_tools_create_non_existing_file_based_on
fichier_local * filesystem_tools_create_non_existing_file_based_on(const std::shared_ptr< user_interaction > &dialog, std::string filename, path where, std::string &new_filename)
create in dirname a brand-new filename which name derives from filename
libdar::filesystem_tools_make_delta_patch
void filesystem_tools_make_delta_patch(const std::shared_ptr< user_interaction > &dialog, const cat_file &existing, const std::string &existing_pathname, const cat_file &patcher, const path &directory, bool hard_linked)
perform binary patch on filesystem
libdar::filesystem_tools_read_linux_birthtime
bool filesystem_tools_read_linux_birthtime(const std::string &target, datetime &val)
read the birthtime of target inode
infinint.hpp
switch module to limitint (32 ou 64 bits integers) or infinint
my_config.h
include macro defined by the configure script and some specific additional ones
libdar
libdar namespace encapsulate all libdar symbols
Definition archive.hpp:47
path.hpp
here is the definition of the path class
user_interaction.hpp
defines the interaction interface between libdar and users.