proxygen
FsUtil.h
Go to the documentation of this file.
1 /*
2  * Copyright 2012-present Facebook, Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #pragma once
18 
19 #include <boost/filesystem.hpp>
20 
21 namespace folly {
22 namespace fs {
23 
24 // Functions defined in this file are meant to extend the
25 // boost::filesystem library; functions will be named according to boost's
26 // naming conventions instead of ours. For convenience, import the
27 // boost::filesystem namespace into folly::fs.
28 using namespace ::boost::filesystem;
29 
39 bool starts_with(const path& p, const path& prefix);
40 
45 path remove_prefix(const path& p, const path& prefix);
46 
52 path canonical_parent(const path& p, const path& basePath = current_path());
53 
66 path executable_path();
67 
68 } // namespace fs
69 } // namespace folly
path executable_path()
Definition: FsUtil.cpp:72
—— Concurrent Priority Queue Implementation ——
Definition: AtomicBitSet.h:29
bool prefix(Cursor &c, uint32_t expected)
path remove_prefix(const path &pth, const path &prefix)
Definition: FsUtil.cpp:50
filesystem
Definition: CMakeCache.txt:563
path canonical_parent(const path &pth, const path &base)
Definition: FsUtil.cpp:68
bool starts_with(const path &pth, const path &prefix)
Definition: FsUtil.cpp:45