public static string ToPlatformPath(this string path) { switch (PlatformIdentifier) { case PlatformID.Win32NT: return path.Replace('/', '\\'); default: return path.ToAvalonPath(); } }