.TH "zipios::FilePath" 3 "Tue May 9 2017" "Zipios++" \" -*- nroff -*- .ad l .nh .SH NAME zipios::FilePath \- \fBFilePath\fP represents a path to a file or directory name\&. .SH SYNOPSIS .br .PP .PP \fC#include \fP .SS "Public Member Functions" .in +1c .ti -1c .RI "\fBFilePath\fP (const string &path='', bool check_exists=false)" .br .RI "Constructor\&. " .ti -1c .RI "\fBFilePath\fP & \fBoperator=\fP (const string &rhs)" .br .ti -1c .RI "\fBoperator string\fP () const" .br .ti -1c .RI "\fBFilePath\fP \fBoperator+\fP (const \fBFilePath\fP &name) const" .br .RI "Concatenates \fBFilePath\fP objects\&. " .ti -1c .RI "\fBFilePath\fP \fBfilename\fP () const" .br .RI "Returns filename of the \fBFilePath\fP object by pruning the path off\&. " .ti -1c .RI "bool \fBexists\fP () const" .br .ti -1c .RI "bool \fBisRegular\fP () const" .br .ti -1c .RI "bool \fBisDirectory\fP () const" .br .ti -1c .RI "bool \fBisCharSpecial\fP () const" .br .ti -1c .RI "bool \fBisBlockSpecial\fP () const" .br .ti -1c .RI "bool \fBisSocket\fP () const" .br .ti -1c .RI "bool \fBisFifo\fP () const" .br .in -1c .SS "Protected Member Functions" .in +1c .ti -1c .RI "void \fBpruneTrailingSeparator\fP ()" .br .RI "Prunes the trailing separator of a specified path\&. " .ti -1c .RI "void \fBcheck\fP () const" .br .RI "This function sets _checked to true, stats the path, to see if it exists and to determine what type of file it is\&. " .in -1c .SS "Protected Attributes" .in +1c .ti -1c .RI "bool \fB_checked\fP" .br .ti -1c .RI "bool \fB_exists\fP" .br .ti -1c .RI "bool \fB_is_reg\fP" .br .ti -1c .RI "bool \fB_is_dir\fP" .br .ti -1c .RI "bool \fB_is_char\fP" .br .ti -1c .RI "bool \fB_is_block\fP" .br .ti -1c .RI "bool \fB_is_socket\fP" .br .ti -1c .RI "bool \fB_is_fifo\fP" .br .ti -1c .RI "string \fB_path\fP" .br .in -1c .SS "Static Protected Attributes" .in +1c .ti -1c .RI "static const char \fB_separator\fP = '/'" .br .in -1c .SH "Detailed Description" .PP \fBFilePath\fP represents a path to a file or directory name\&. \fBFilePath\fP has member functions to check if the file path is a valid file system entity, and to check what kind of file system entity it is, e\&.g\&. is it a file, a directory, a pipe etc\&. .PP Definition at line 18 of file filepath\&.h\&. .SH "Constructor & Destructor Documentation" .PP .SS "zipios::FilePath::FilePath (const string & path = \fC''\fP, bool check_exists = \fCfalse\fP)" .PP Constructor\&. .PP \fBParameters:\fP .RS 4 \fIpath\fP A string representation of the path\&. .br \fIcheck_exists\fP If true is specified the constructor will check the existence and type of the path immidiately, instead of deferring that task until it is needed\&. .RE .PP .PP Definition at line 18 of file filepath\&.cpp\&. .SH "Member Function Documentation" .PP .SS "void zipios::FilePath::check () const\fC [protected]\fP" .PP This function sets _checked to true, stats the path, to see if it exists and to determine what type of file it is\&. All the query functions check if _checked is true, and if it isn't they call \fBcheck()\fP\&. This means stat'ing is deferred until it becomes necessary\&. .PP Definition at line 27 of file filepath\&.cpp\&. .SS "bool zipios::FilePath::exists () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true If the path is a valid file system entity\&. .RE .PP .PP Definition at line 129 of file filepath\&.h\&. .SS "\fBFilePath\fP zipios::FilePath::filename () const\fC [inline]\fP" .PP Returns filename of the \fBFilePath\fP object by pruning the path off\&. .PP Definition at line 119 of file filepath\&.h\&. .SS "bool zipios::FilePath::isBlockSpecial () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is block special (a block device file)\&. .RE .PP .PP Definition at line 157 of file filepath\&.h\&. .SS "bool zipios::FilePath::isCharSpecial () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is character special (a character device file)\&. .RE .PP .PP Definition at line 150 of file filepath\&.h\&. .SS "bool zipios::FilePath::isDirectory () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is a directory\&. .RE .PP .PP Definition at line 143 of file filepath\&.h\&. .SS "bool zipios::FilePath::isFifo () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is a Fifo (a pipe)\&. .RE .PP .PP Definition at line 171 of file filepath\&.h\&. .SS "bool zipios::FilePath::isRegular () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is a regular file\&. .RE .PP .PP Definition at line 136 of file filepath\&.h\&. .SS "bool zipios::FilePath::isSocket () const\fC [inline]\fP" .PP \fBReturns:\fP .RS 4 true if the path is a socket\&. .RE .PP .PP Definition at line 164 of file filepath\&.h\&. .SS "\fBFilePath\fP zipios::FilePath::operator+ (const \fBFilePath\fP & name) const\fC [inline]\fP" .PP Concatenates \fBFilePath\fP objects\&. A file separator is inserted if appropriate\&. .PP Definition at line 111 of file filepath\&.h\&. .SS "void zipios::FilePath::pruneTrailingSeparator ()\fC [inline]\fP, \fC [protected]\fP" .PP Prunes the trailing separator of a specified path\&. .PP Definition at line 100 of file filepath\&.h\&. .SH "Author" .PP Generated automatically by Doxygen for Zipios++ from the source code\&.