Doxygen
Loading...
Searching...
No Matches
DirEntry Class Reference

#include <src/dir.h>

Classes

struct  Private
 

Public Member Functions

 ~DirEntry ()
 
 DirEntry (const DirEntry &)
 
DirEntryoperator= (const DirEntry &)
 
 DirEntry (DirEntry &&)
 
DirEntryoperator= (DirEntry &&)
 
bool is_directory () const
 
bool is_regular_file () const
 
bool is_symlink () const
 
std::string path () const
 

Private Member Functions

 DirEntry ()
 

Private Attributes

std::unique_ptr< Privatep
 

Friends

class DirIterator
 

Detailed Description

Definition at line 24 of file dir.h.

Constructor & Destructor Documentation

◆ ~DirEntry()

DirEntry::~DirEntry ( )
default

References DirEntry().

◆ DirEntry() [1/3]

DirEntry::DirEntry ( const DirEntry & de)

Definition at line 37 of file dir.cpp.

37 : p(std::make_unique<Private>())
38{
39 p->entry = de.p->entry;
40}
std::unique_ptr< Private > p
Definition dir.h:40

References DirEntry(), and p.

Referenced by DirEntry(), DirEntry(), operator=(), operator=(), and ~DirEntry().

◆ DirEntry() [2/3]

DirEntry::DirEntry ( DirEntry && de)

Definition at line 52 of file dir.cpp.

52 : p(std::make_unique<Private>())
53{
54 p = std::move(de.p);
55}

References DirEntry(), and p.

◆ DirEntry() [3/3]

DirEntry::DirEntry ( )
private

Definition at line 33 of file dir.cpp.

33 : p(std::make_unique<Private>())
34{
35}

References p.

Member Function Documentation

◆ is_directory()

bool DirEntry::is_directory ( ) const

Definition at line 65 of file dir.cpp.

66{
67 return p->entry.is_directory();
68}

References p.

◆ is_regular_file()

bool DirEntry::is_regular_file ( ) const

Definition at line 70 of file dir.cpp.

71{
72 return p->entry.is_regular_file();
73}

References p.

◆ is_symlink()

bool DirEntry::is_symlink ( ) const

Definition at line 75 of file dir.cpp.

76{
77 return p->entry.is_symlink();
78}

References p.

◆ operator=() [1/2]

DirEntry & DirEntry::operator= ( const DirEntry & de)

Definition at line 42 of file dir.cpp.

43{
44 if (this!=&de)
45 {
46 p = std::make_unique<Private>();
47 p->entry = de.p->entry;
48 }
49 return *this;
50}

References DirEntry(), and p.

◆ operator=() [2/2]

DirEntry & DirEntry::operator= ( DirEntry && de)

Definition at line 57 of file dir.cpp.

58{
59 p = std::move(de.p);
60 return *this;
61}

References DirEntry(), and p.

◆ path()

std::string DirEntry::path ( ) const

Definition at line 80 of file dir.cpp.

81{
82 return p->entry.path().string();
83}

References p.

Friends And Related Symbol Documentation

◆ DirIterator

friend class DirIterator
friend

Definition at line 37 of file dir.h.

References DirIterator.

Referenced by DirIterator.

Member Data Documentation

◆ p

std::unique_ptr<Private> DirEntry::p
private

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