FEDEM Model Database  R8.0
Source code of the FEDEM model database
FmModelFileQuery.H
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: 2023 SAP SE
2 //
3 // SPDX-License-Identifier: Apache-2.0
4 //
5 // This file is part of FEDEM - https://openfedem.org
7 
8 #ifndef FM_MODEL_FILE_QUERY_H
9 #define FM_MODEL_FILE_QUERY_H
10 
11 #include <string>
12 #include <vector>
13 
14 
26 {
27 public:
28  FmModelFileQuery(const std::string& filePath = "") : myModelFile(filePath) {}
29 
30  std::vector<std::string> getEntries(const std::string& keyWord, bool all = true);
31  std::string getFirstEntry(const std::string& keyWord);
32 
33 private:
34  std::string myModelFile;
35 };
36 
37 #endif
Utility to query the contents of a model file by keyWord.
Definition: FmModelFileQuery.H:26
FmModelFileQuery(const std::string &filePath="")
Definition: FmModelFileQuery.H:28
std::vector< std::string > getEntries(const std::string &keyWord, bool all=true)
Returns the values of the provided keyword.
Definition: FmModelFileQuery.C:23
std::string myModelFile
Definition: FmModelFileQuery.H:34
std::string getFirstEntry(const std::string &keyWord)
Definition: FmModelFileQuery.C:80