m/directory: Added directory_parts method