예제 #1
0
파일: TeaSafe.cpp 프로젝트: airk42/teasafe
 void
 TeaSafe::throwIfAlreadyExists(std::string const &path) const
 {
     // throw if already exists
     boost::filesystem::path processedPath(path);
     if (doFileExists(processedPath.string())) {
         throw TeaSafeException(TeaSafeError::AlreadyExists);
     }
     if (doFolderExists(processedPath.string())) {
         throw TeaSafeException(TeaSafeError::AlreadyExists);
     }
 }
예제 #2
0
파일: CoreFS.cpp 프로젝트: benhj/KnoxCrypt
 void
 CoreFS::throwIfAlreadyExists(std::string const &path) const
 {
     // throw if already exists
     boost::filesystem::path processedPath(path);
     if (doFileExists(processedPath.string())) {
         throw KnoxCryptException(KnoxCryptError::AlreadyExists);
     }
     if (doFolderExists(processedPath.string())) {
         throw KnoxCryptException(KnoxCryptError::AlreadyExists);
     }
 }