17 [SecuritySafeCritical]
23 string text = stringBuilder.
ToString();
30 [Obsolete(
"Do not create instances of the RuntimeEnvironment class. Call the static methods directly on this type instead",
true)]
37 internal static extern string GetModuleFileName();
41 internal static extern string GetDeveloperPath();
45 internal static extern string GetHostBindingFile();
49 [SuppressUnmanagedCodeSecurity]
50 internal static extern void _GetSystemVersion(StringHandleOnStack retVer);
64 [SecuritySafeCritical]
68 _GetSystemVersion(JitHelpers.GetStringHandleOnStack(ref s));
74 [SecuritySafeCritical]
77 string runtimeDirectoryImpl = GetRuntimeDirectoryImpl();
79 return runtimeDirectoryImpl;
84 internal static extern string GetRuntimeDirectoryImpl();
88 [SuppressUnmanagedCodeSecurity]
101 return GetRuntimeInterfaceImpl(clsid, riid);
117 intPtr = GetRuntimeInterfaceImpl(clsid, riid);
FileIOPermissionAccess
Specifies the type of file access requested.
unsafe override string ToString()
Converts the value of this instance to a T:System.String.
static IntPtr GetRuntimeInterfaceAsIntPtr(Guid clsid, Guid riid)
Returns the specified interface on the specified class.
static int Release(IntPtr pUnk)
Decrements the reference count on the specified interface.
Provides a collection of static methods that return information about the common language runtime env...
static string GetRuntimeDirectory()
Returns the directory where the common language runtime is installed.
static string SystemConfigurationFile
Gets the path to the system configuration file.
Represents assembly binding information that can be added to an instance of T:System....
Represents a globally unique identifier (GUID).To browse the .NET Framework source code for this type...
static string GetSystemVersion()
Gets the version number of the common language runtime that is running the current process.
StringBuilder Append(char value, int repeatCount)
Appends a specified number of copies of the string representation of a Unicode character to this inst...
UnmanagedType
Identifies how to marshal parameters or fields to unmanaged code.
Represents an assembly, which is a reusable, versionable, and self-describing building block of a com...
A platform-specific type that is used to represent a pointer or a handle.
virtual bool GlobalAssemblyCache
Gets a value indicating whether the assembly was loaded from the global assembly cache.
Provides a collection of methods for allocating unmanaged memory, copying unmanaged memory blocks,...
MethodImplOptions
Defines the details of how a method is implemented.
CharSet
Dictates which character set marshaled strings should use.
Represents a mutable string of characters. This class cannot be inherited.To browse the ....
static object GetRuntimeInterfaceAsObject(Guid clsid, Guid riid)
Returns an instance of a type that represents a COM object by a pointer to its IUnknown interface.
void Demand()
Forces a T:System.Security.SecurityException at run time if all callers higher in the call stack have...
RuntimeEnvironment()
Initializes a new instance of the T:System.Runtime.InteropServices.RuntimeEnvironment class.
static readonly IntPtr Zero
A read-only field that represents a pointer or handle that has been initialized to zero.
static bool FromGlobalAccessCache(Assembly a)
Tests whether the specified assembly is loaded in the global assembly cache.
Controls the ability to access files and folders. This class cannot be inherited.
static object GetObjectForIUnknown(IntPtr pUnk)
Returns an instance of a type that represents a COM object by a pointer to its IUnknown interface.