some changes to  PathString
fix java compatability test