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

Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
libdar::filesystem_hard_link_write Class Reference
Private

keep trace of already written inodes to restore hard links More...

`#include <filesystem_hard_link_write.hpp>`

Inherits libdar::mem_ui.

Inherited by libdar::filesystem_restore.

## Public Member Functions
| filesystem_hard_link_write (const std::shared_ptr< user_interaction > &dialog)
| filesystem_hard_link_write (const filesystem_hard_link_write &ref)=delete
| filesystem_hard_link_write (filesystem_hard_link_write &&ref)=delete
filesystem_hard_link_write & | operator= (const filesystem_hard_link_write &ref)=delete
filesystem_hard_link_write & | operator= (filesystem_hard_link_write &&ref)=delete
void | write_hard_linked_target_if_not_set (const cat_mirage *ref, const std::string &chemin)
bool | known_etiquette (const infinint &eti)
void | clear_corres_if_pointing_to (const infinint &ligne, const std::string &path)
| forget everything about a hard link if the path used to build subsequent hard links is the one given in argument

## Protected Member Functions
void | corres_reset ()
void | make_file (const cat_nomme *ref, const path &ou)
| generate inode or make a hard link on an already restored or existing inode.
bool | raw_set_ea (const cat_nomme *e, const ea_attributs &list_ea, const std::string &spot, const mask &ea_mask)
| add the given EA matching the given mask to the file pointed to by "e" and spot
bool | raw_clear_ea_set (const cat_nomme *e, const std::string &path)
| remove EA set from filesystem's file, allows subsequent raw_set_ea
Protected Member Functions inherited from libdar::mem_ui
user_interaction & | get_ui () const
| get access to the user_interaction object
std::shared_ptr< user_interaction > | get_pointer () const
| get access to the shared_ptr pointing to the user_interaction
void | change_ui (const std::shared_ptr< user_interaction > &new_dialog)
| change the user_interaction object
| mem_ui (const std::shared_ptr< user_interaction > &dialog)
| constructor
| mem_ui (const mem_ui &ref)=default
| the copy constructor
| mem_ui (mem_ui &&ref) noexcept=default
| the move constructor
mem_ui & | operator= (const mem_ui &ref)=default
| assignement operator
mem_ui & | operator= (mem_ui &&ref) noexcept=default
| move operator
virtual | ~mem_ui () noexcept(false)
| destructor

## Private Attributes
std::map< infinint, corres_ino_ea > | corres_write

## Detailed Description

keep trace of already written inodes to restore hard links

Definition at line 57 of file filesystem_hard_link_write.hpp.

## Constructor & Destructor Documentation

## ◆ filesystem_hard_link_write()

libdar::filesystem_hard_link_write::filesystem_hard_link_write | ( | const std::shared_ptr< user_interaction > & | dialog | ) |
| inline

Definition at line 63 of file filesystem_hard_link_write.hpp.

## Member Function Documentation

## ◆ clear_corres_if_pointing_to()

void libdar::filesystem_hard_link_write::clear_corres_if_pointing_to | ( | const infinint & | ligne,
|  | const std::string & | path )

forget everything about a hard link if the path used to build subsequent hard links is the one given in argument

Parameters

  [in] | ligne | is the etiquette number for that hard link
  [in] | path | if the internaly recorded path to build subsequent hard link to that inode is equal to path, forget everything about this hard linked inode

## ◆ corres_reset()

void libdar::filesystem_hard_link_write::corres_reset | ( |  | ) |
| inline protected

Definition at line 85 of file filesystem_hard_link_write.hpp.

## ◆ known_etiquette()

bool libdar::filesystem_hard_link_write::known_etiquette | ( | const infinint & | eti | ) |

Returns
  true if an inode in filesystem has been seen for that hard linked inode

## ◆ make_file()

void libdar::filesystem_hard_link_write::make_file | ( | const cat_nomme * | ref,
|  | const path & | ou )
| protected

generate inode or make a hard link on an already restored or existing inode.

Parameters

  [in] | ref | object to restore in filesystem
  [in] | ou | where to restore it

## ◆ raw_clear_ea_set()

bool libdar::filesystem_hard_link_write::raw_clear_ea_set | ( | const cat_nomme * | e,
|  | const std::string & | path )
| protected

remove EA set from filesystem's file, allows subsequent raw_set_ea

Parameters

  [in] | e | this object may be a hard link to or an inode
  [in] | path | the path in the filesystem where reside the object whose EA to clear

Returns
  true if EA could be cleared, false if "e" is a hard link to an inode that has its EA already restored previously

## ◆ raw_set_ea()

bool libdar::filesystem_hard_link_write::raw_set_ea | ( | const cat_nomme * | e,
|  | const ea_attributs & | list_ea,
|  | const std::string & | spot,
|  | const mask & | ea_mask )
| protected

add the given EA matching the given mask to the file pointed to by "e" and spot

Parameters

  [in] | e | may be an inode or a hard link to an inode,
  [in] | list_ea | the list of EA to restore
  [in] | spot | the path where to restore these EA (full path required, including the filename of 'e')
  [in] | ea_mask | the EA entry to restore from the list_ea (other entries are ignored)

Returns
  true if EA could be restored, false if "e" is a hard link to an inode that has its EA already restored previously

Note
  the list_ea EA are restored to spot path, the object e is only here to validate that this operation has not already been done through another hard linked inode to that same inode

## Member Data Documentation

## ◆ corres_write

std::map<infinint, corres_ino_ea> libdar::filesystem_hard_link_write::corres_write
| private

Definition at line 125 of file filesystem_hard_link_write.hpp.

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

- filesystem_hard_link_write.hpp