configuration_file_resolver.h
Go to the documentation of this file.
1 /*
2  * Copyright 2016 The Cartographer Authors
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 #ifndef CARTOGRAPHER_COMMON_CONFIGURATION_FILE_RESOLVER_H_
18 #define CARTOGRAPHER_COMMON_CONFIGURATION_FILE_RESOLVER_H_
19 
20 #include <vector>
21 
24 
25 namespace cartographer {
26 namespace common {
27 
28 // A 'FileResolver' for the 'LuaParameterDictionary' that reads files from disk.
29 // It searches the 'configuration_files_directories' in order to find the
30 // requested filename. The last place searched is always the
31 // 'configuration_files/' directory installed with Cartographer. It contains
32 // reasonable configuration for the various Cartographer components which
33 // provide a good starting ground for new platforms.
35  public:
37  const std::vector<string>& configuration_files_directories);
38 
39  string GetFullPathOrDie(const string& basename) override;
40  string GetFileContentOrDie(const string& basename) override;
41 
42  private:
43  std::vector<string> configuration_files_directories_;
44 };
45 
46 } // namespace common
47 } // namespace cartographer
48 
49 #endif // CARTOGRAPHER_COMMON_CONFIGURATION_FILE_RESOLVER_H_
ConfigurationFileResolver(const std::vector< string > &configuration_files_directories)
string GetFullPathOrDie(const string &basename) override
string GetFileContentOrDie(const string &basename) override


cartographer
Author(s):
autogenerated on Wed Jun 5 2019 21:57:58