added separate methods getPath, getHost
fixes