FBX2glTF/src/utils/File_Utils.hpp

32 lines
863 B
C++

/**
* Copyright (c) 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#pragma once
#include <string>
#include <vector>
namespace FileUtils {
std::string GetCurrentFolder();
bool FileExists(const std::string& folderPath);
bool FolderExists(const std::string& folderPath);
bool MatchExtension(const char* fileExtension, const char* matchExtensions);
std::vector<std::string> ListFolderFiles(const char* folder, const char* matchExtensions);
bool CreatePath(const char* path);
bool CopyFile(
const std::string& srcFilename,
const std::string& dstFilename,
bool createPath = false);
} // namespace FileUtils