mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
Files
f7592cb5b4ece7585db38b79cb28890e3fe7d379
33 lines
781 B
C#
33 lines
781 B
C#
using System;
|
|||
using System.Collections.Generic;
|
|||
using System.Linq;
|
|||
using System.Text;
|
|||
using System.Threading.Tasks;
|
|||
|
|||
namespace Tools.DotNETCommon.Perforce
|
|||
{
|
|||
public static class PerforceUtils
|
|||
{
|
|||
static public string EscapePath(string Path)
|
|||
{
|
|||
string NewPath = Path;
|
|||
NewPath = NewPath.Replace("%", "%25");
|
|||
NewPath = NewPath.Replace("*", "%2A");
|
|||
NewPath = NewPath.Replace("#", "%23");
|
|||
NewPath = NewPath.Replace("@", "%40");
|
|||
return NewPath;
|
|||
}
|
|||
|
|||
static public string UnescapePath(string Path)
|
|||
{
|
|||
string NewPath = Path;
|
|||
NewPath = NewPath.Replace("%40", "@");
|
|||
NewPath = NewPath.Replace("%23", "#");
|
|||
NewPath = NewPath.Replace("%2A", "*");
|
|||
NewPath = NewPath.Replace("%2a", "*");
|
|||
NewPath = NewPath.Replace("%25", "%");
|
|||
return NewPath;
|
|||
}
|
|||
}
|
|||
}
|