로딩중...
검색중...
일치하는것 없음
by::fsystem 클래스 참조

Cross-platform filesystem utilities for recursive file traversal 더 자세히 ...

#include <fsystem.hpp>

정적 Public 멤버 함수

static iterator find (const std::string &path)
 Creates iterator for recursive filesystem traversal
 
static std::string getCurrentDir ()
 
static const std::string & getDelimiter ()
 

상세한 설명

Cross-platform filesystem utilities for recursive file traversal

A simple class for recursively traversing files in a specified folder. Provides platform-independent API that works on both Windows and POSIX-compliant operating systems. Core functionality is provided through the iterator class.

Usage

Basic usage example:

auto e = fsystem::find("../your/path");
while(e.next()) { // Returns false when all files are traversed
const std::string& path = *e; // Path of the found file
if(*e == "../your/path/child/helloWorld.cpp") // Always uses relative paths
doSomething(e->getDir()); // Returns the folder path of the found file
}
static iterator find(const std::string &path)
Creates iterator for recursive filesystem traversal
Rich logging support with polymorphic type conversion
Definition richLog.hpp:34
Remarks
Always iterates files only Empty folders are skipped during iteration.

supports partial glob patterns

You can use aterisk (*) and question mark (?) wildcards in the pattern.

auto e = fsystem::find("*.cpp"); // the only difference is here
while(e.next()) {
const std::string& path = *e;
if(*e == "your/path/child/helloWorld.cpp")
doSomething(e->getDir());
}

멤버 함수 문서화

◆ find()

static iterator by::fsystem::find ( const std::string & path)
static

Creates iterator for recursive filesystem traversal

반환값
iterator positioned at first file, or at end if path invalid
주의
Automatically traverses subdirectories recursively, yielding only files

이 클래스에 대한 문서화 페이지는 다음의 파일로부터 생성되었습니다.: