#pragma once #include #include namespace XAttrTk { extern const std::string UserXAttrPrefix; std::pair> listXAttrs(const std::string& path); std::tuple, ssize_t> getXAttr(const std::string& path, const std::string& name, size_t maxSize); void sanitizeForUser(std::vector& names); void removeMetadataAttrs(std::vector& names); FhgfsOpsErr setUserXAttr(const std::string& path, const std::string& name, const void* value, size_t size, int flags); FhgfsOpsErr removeUserXAttr(const std::string& path, const std::string& name); inline std::tuple, ssize_t> getUserXAttr(const std::string& path, const std::string& name, size_t maxSize) { return getXAttr(path, UserXAttrPrefix + name, maxSize); } std::pair> listUserXAttrs(const std::string& path); }