markus / ConvertService / ServiceController / Markus.Service.Extensions / Helper / UriHelper.cs @ 5c387707
이력 | 보기 | 이력해설 | 다운로드 (551 Bytes)
1 |
using System; |
---|---|
2 |
using System.Collections.Generic; |
3 |
using System.Linq; |
4 |
using System.Text; |
5 |
using System.Threading.Tasks; |
6 |
|
7 |
namespace Markus.Service.Helper |
8 |
{ |
9 |
public static class UriHelper |
10 |
{ |
11 |
public static Uri UriCreate(string UriString) |
12 |
{ |
13 |
Uri result = null; |
14 |
|
15 |
if (Uri.TryCreate(UriString, UriKind.Absolute, out result)) |
16 |
{ |
17 |
return result; |
18 |
} |
19 |
else |
20 |
{ |
21 |
throw new Exception("UriString is Not UriType"); |
22 |
} |
23 |
} |
24 |
} |
25 |
} |