33#ifndef DART_UTILS_PACKAGERESOURCERETRIEVER_HPP_
34#define DART_UTILS_PACKAGERESOURCERETRIEVER_HPP_
36#include <unordered_map>
88 const std::string& _packageName,
const std::string& _packageDirectory);
101 std::unordered_map<std::string, std::vector<std::string> >
mPackageMap;
104 const std::string& _packageName)
const;
107 std::string& _packageName,
108 std::string& _relativePath)
const;
#define DART_DECLARE_CLASS_WITH_VIRTUAL_BASE_END
Definition ClassWithVirtualBase.hpp:44
#define DART_DECLARE_CLASS_WITH_VIRTUAL_BASE_BEGIN
Definition ClassWithVirtualBase.hpp:43
ResourceRetriever provides methods for testing for the existance of and accessing the content of a re...
Definition ResourceRetriever.hpp:47
Retrieve local resources specified by package:// URIs by: (1) resolving the package path and (2) pass...
Definition PackageResourceRetriever.hpp:51
std::string getFilePath(const common::Uri &uri) override
Returns absolute file path to uri; an empty string if unavailable.
Definition PackageResourceRetriever.cpp:107
std::unordered_map< std::string, std::vector< std::string > > mPackageMap
Definition PackageResourceRetriever.hpp:101
void addPackageDirectory(const std::string &_packageName, const std::string &_packageDirectory)
Specify the directory of a ROS package.
Definition PackageResourceRetriever.cpp:55
virtual ~PackageResourceRetriever()=default
common::ResourcePtr retrieve(const common::Uri &_uri) override
Returns the resource specified by a URI or nullptr on failure.
Definition PackageResourceRetriever.cpp:89
bool exists(const common::Uri &_uri) override
Returns whether the resource specified by a URI exists.
Definition PackageResourceRetriever.cpp:70
const std::vector< std::string > & getPackagePaths(const std::string &_packageName) const
Definition PackageResourceRetriever.cpp:129
common::ResourceRetrieverPtr mLocalRetriever
Definition PackageResourceRetriever.hpp:100
bool resolvePackageUri(const common::Uri &_uri, std::string &_packageName, std::string &_relativePath) const
Definition PackageResourceRetriever.cpp:150
std::shared_ptr< Resource > ResourcePtr
Definition Resource.hpp:90
std::shared_ptr< ResourceRetriever > ResourceRetrieverPtr
Definition ResourceRetriever.hpp:76
std::shared_ptr< PackageResourceRetriever > PackageResourceRetrieverPtr
Definition PackageResourceRetriever.hpp:112
Definition BulletCollisionDetector.cpp:65
The Uri struct provides URI parsing and merging functionality based on RFC 3986.
Definition Uri.hpp:87