diff options
author | Andreas Stöckel <astoecke@techfak.uni-bielefeld.de> | 2015-02-16 20:47:07 +0100 |
---|---|---|
committer | Andreas Stöckel <astoecke@techfak.uni-bielefeld.de> | 2015-02-16 20:47:07 +0100 |
commit | 4a4e2245730ead7fce354469fe626398520f12b2 (patch) | |
tree | af42dbf2fd9ea87884cd500367c4017293609863 /src/core/Registry.hpp | |
parent | 6de2c8ad9450a8b349161d37ad7cab538324034d (diff) | |
parent | 75eea3bdd846a34c69be3d09f41ff4fae706628e (diff) |
using remote version of simple_book.osml
Diffstat (limited to 'src/core/Registry.hpp')
-rw-r--r-- | src/core/Registry.hpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/core/Registry.hpp b/src/core/Registry.hpp index 4b4cb65..b4ce1a9 100644 --- a/src/core/Registry.hpp +++ b/src/core/Registry.hpp @@ -30,6 +30,7 @@ #include <map> #include <set> +#include <string> #include <vector> #include <core/common/Rtti.hpp> @@ -153,6 +154,23 @@ public: bool locateResource(Resource &resource, const std::string &path, ResourceType type = ResourceType::UNKNOWN, const Resource &relativeTo = NullResource) const; + + /** + * Performs autocompletion of resources with missing file extension and + * returns a list of possible files existing within the filesystem. + * + * @param path is the path for which the autocompletion shuold be performed. + * @param type is the ResourceType which is used to select the search paths. + * @param relativeTo is another resource relatie to which the resource may + * be looked up. + * @return a list of possible files to which the given path may be extended. + * If the file pointed to by "path" exists, it will be the only result in + * the list. Otherwise files which have the given path as a prefix but a + * different file extension are returned. + */ + std::vector<std::string> autocompleteResource( + const std::string &path, ResourceType type = ResourceType::UNKNOWN, + const Resource &relativeTo = NullResource) const; }; } |