Gazebo Fuel_tools

API Reference

10.0.0
Model.hh
Go to the documentation of this file.
1/*
2 * Copyright (C) 2017 Open Source Robotics Foundation
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
18#ifndef GZ_FUEL_TOOLS_MODEL_HH_
19#define GZ_FUEL_TOOLS_MODEL_HH_
20
21#include <memory>
22#include <string>
23
27
28#ifdef _WIN32
29// Disable warning C4251 which is triggered by
30// std::shared_ptr
31#pragma warning(push)
32#pragma warning(disable: 4251)
33#endif
34
35namespace gz::fuel_tools
36{
38 class ModelPrivate;
39
41 class ModelIter;
42
44 class ModelIterPrivate;
45
47 class LocalCache;
48
50 class LocalCachePrivate;
51
53 class IterIds;
54
56 class IterRESTIds;
57
59 class IterRestIds;
60
62 class ModelIterTest;
63
65 class GZ_FUEL_TOOLS_VISIBLE Model
66 {
67 friend IterIds;
68 friend IterRESTIds;
69 friend IterRestIds;
70 friend ModelIter;
71 friend ModelIterPrivate;
72 friend ModelIterTest;
73 friend LocalCache;
74 friend LocalCachePrivate;
75
77 public: Model();
78
81 public: Model(const Model &_orig) = default;
82
85 protected: explicit Model(std::shared_ptr<ModelPrivate> _dptr);
86
88 public: operator bool() const;
89
92 public: operator bool();
93
97
101 public: Result Fetch() const;
102
106 public: std::string PathToModel() const;
107
109 private: std::shared_ptr<ModelPrivate> dataPtr;
110 };
111} // namespace gz::fuel_tools
112
113#ifdef _MSC_VER
114#pragma warning(pop)
115#endif
116
117#endif // GZ_FUEL_TOOLS_MODEL_HH_