Freigeben über


Environment.WorkingSet-Eigenschaft

Ruft die Größe des physikalischen Speichers ab, der dem Prozesskontext zugeordnet ist.

Namespace: System
Assembly: mscorlib (in mscorlib.dll)

Syntax

'Declaration
Public Shared ReadOnly Property WorkingSet As Long
'Usage
Dim value As Long

value = Environment.WorkingSet
public static long WorkingSet { get; }
public:
static property long long WorkingSet {
    long long get ();
}
/** @property */
public static long get_WorkingSet ()
public static function get WorkingSet () : long

Eigenschaftenwert

Eine 64-Bit-Ganzzahl mit Vorzeichen, die die Größe des dem Prozesskontext zugeordneten physikalischen Speichers in Bytes angibt.

Hinweise

Hinweis zu Windows 98, Windows Millennium Edition: Diese Eigenschaft gibt immer null zurück.

Beispiel

Im folgenden Codebeispiel wird die Größe des Workingsets des Computers angezeigt, auf dem das Codebeispiel ausgeführt wird.

' Sample for the Environment.WorkingSet property
Imports System

Class Sample
   Public Shared Sub Main()
      Console.WriteLine("WorkingSet: {0}", Environment.WorkingSet)
   End Sub 'Main
End Class 'Sample
'
'This example produces the following results:
'
'WorkingSet: 5038080
'
// Sample for the Environment.WorkingSet property
using System;

class Sample 
{
    public static void Main() 
    {
    Console.WriteLine("WorkingSet: {0}", Environment.WorkingSet);
    }
}
/*
This example produces the following results:

WorkingSet: 5038080
*/
// Sample for the Environment::WorkingSet property
using namespace System;
int main()
{
   Console::WriteLine( "WorkingSet: {0}", Environment::WorkingSet );
}

/*
This example produces the following results:

WorkingSet: 5038080
*/
// Sample for the Environment.WorkingSet property
import System.*;

class Sample
{
    public static void main(String[] args)
    {
        Console.WriteLine("WorkingSet: {0}", 
            System.Convert.ToString(Environment.get_WorkingSet()));
    } //main
} //Sample

/*
This example produces the following results:

WorkingSet: 5038080
*/

.NET Framework-Sicherheit

Plattformen

Windows 98, Windows 2000 SP4, Windows CE, Windows Mobile für Pocket PC, Windows Mobile für Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

.NET Framework unterstützt nicht alle Versionen sämtlicher Plattformen. Eine Liste der unterstützten Versionen finden Sie unter Systemanforderungen.

Versionsinformationen

.NET Framework

Unterstützt in: 2.0, 1.1, 1.0

Siehe auch

Referenz

Environment-Klasse
Environment-Member
System-Namespace