[path] Implement relative() method