mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-18 03:51:19 -10:00
* System.ComponentModel/IExtenderProvider.cs: mono-stylized. * System.ComponentModel/IComNativeDescriptorHandler.cs: * System.ComponentModel/SyntaxCheck.cs: new files from Andreas Nahr. svn path=/trunk/mcs/; revision=15567
54 lines
844 B
C#
54 lines
844 B
C#
//
|
|
// System.ComponentModel.SyntaxCheck
|
|
//
|
|
// Author:
|
|
// Andreas Nahr ([email protected])
|
|
//
|
|
// (C) 2003 Andreas Nahr
|
|
//
|
|
|
|
using System.IO;
|
|
|
|
namespace System.ComponentModel
|
|
{
|
|
public class SyntaxCheck
|
|
{
|
|
private SyntaxCheck ()
|
|
{
|
|
}
|
|
|
|
[MonoTODO]
|
|
public static bool CheckMachineName (string value)
|
|
{
|
|
if (value == null || value.Trim () == "")
|
|
return false;
|
|
|
|
return Environment.MachineName.Equals (value);
|
|
}
|
|
|
|
[MonoTODO]
|
|
public static bool CheckPath (string value)
|
|
{
|
|
if (value == null || value.Trim () == "")
|
|
return false;
|
|
|
|
try {
|
|
Path.GetFullPath (value);
|
|
} catch {
|
|
return false;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
[MonoTODO]
|
|
public static bool CheckRootedPath (string value)
|
|
{
|
|
if (value == null || value.Trim () == "")
|
|
return false;
|
|
|
|
return Path.IsPathRooted (value);
|
|
}
|
|
}
|
|
}
|
|
|