StoragePlugin: add method MapToRelativeUTF8()
Replaces map_to_relative_path() from Mapper.cxx.
This commit is contained in:
@@ -68,6 +68,8 @@ public:
|
||||
|
||||
virtual AllocatedPath MapFS(const char *uri_utf8) const override;
|
||||
|
||||
virtual const char *MapToRelativeUTF8(const char *uri_utf8) const override;
|
||||
|
||||
private:
|
||||
AllocatedPath MapFS(const char *uri_utf8, Error &error) const;
|
||||
};
|
||||
@@ -130,6 +132,12 @@ LocalStorage::MapFS(const char *uri_utf8) const
|
||||
return MapFS(uri_utf8, IgnoreError());
|
||||
}
|
||||
|
||||
const char *
|
||||
LocalStorage::MapToRelativeUTF8(const char *uri_utf8) const
|
||||
{
|
||||
return PathTraitsUTF8::Relative(base_utf8.c_str(), uri_utf8);
|
||||
}
|
||||
|
||||
bool
|
||||
LocalStorage::GetInfo(const char *uri_utf8, bool follow, FileInfo &info,
|
||||
Error &error)
|
||||
|
Reference in New Issue
Block a user