PSEventManager Class
TOC
Collapse the table of content
Expand the table of content

PSEventManager Class

 

Updated: April 27, 2016

Applies To: Windows PowerShell

Represents the base functionality of a Windows PowerShell event manager that handles subscribing to and receiving events that are raised by Windows PowerShell. This class is introduced in Windows PowerShell 2.0.

Namespace:   System.Management.Automation
Assembly:  System.Management.Automation (in System.Management.Automation.dll)

System.Object
  System.Management.Automation.PSEventManager

Public MustInherit Class PSEventManager

NameDescription
System_CAPS_protmethodPSEventManager()

Initializes a new instance of the PSEventManager class. This constructor is introduced by Windows PowerShell 2.0.

NameDescription
System_CAPS_pubpropertyReceivedEvents

Gets the events that were raised in the current runspace. This property is introduced in Windows PowerShell 2.0.

System_CAPS_pubpropertySubscribers

When overridden in a derived class, gets a list of the objects that currently subscribe to the event. This property is introduced in Windows PowerShell 2.0.

NameDescription
System_CAPS_protmethodCreateEvent(String, Object, Object(), PSObject)

When overridden in a derived class, creates a Windows PowerShell event.

System_CAPS_pubmethodEquals(Object)

(Inherited from Object.)

System_CAPS_protmethodFinalize()

(Inherited from Object.)

System_CAPS_pubmethodGenerateEvent(String, Object, Object(), PSObject)

Raises an event in the current runspace. This method is introduced in Windows PowerShell 2.0.

System_CAPS_pubmethodGenerateEvent(String, Object, Object(), PSObject, Boolean, Boolean)

Generate a PowerShell event.

System_CAPS_pubmethodGetEventSubscribers(String)

When overridden in a derived class, retrieves the objects that catch an event when it is raised. This method is introduced in Windows PowerShell 2.0.

System_CAPS_pubmethodGetHashCode()

(Inherited from Object.)

System_CAPS_protmethodGetNextEventId()

Generates a sequential event identifier.

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

(Inherited from Object.)

System_CAPS_protmethodProcessNewEvent(PSEventArgs, Boolean)

When overridden in a derived class, processes new events that have either been generated by this instance or forwarded to it.

System_CAPS_protmethodProcessNewEvent(PSEventArgs, Boolean, Boolean)

Processes new events that have either been generated by this instance or forwarded to it. Introduced in Windows PowerShell 3.0.

System_CAPS_pubmethodSubscribeEvent(Object, String, String, PSObject, PSEventReceivedEventHandler, Boolean, Boolean)

When overridden in a derived class, creates a subscriber to an event and specifies the event handler object. This method is introduced in Windows PowerShell 2.0.

System_CAPS_pubmethodSubscribeEvent(Object, String, String, PSObject, PSEventReceivedEventHandler, Boolean, Boolean, Int32)

When overridden in a derived class, creates a subscriber to an event, specifies the event handler object, and specifies the maximum number of times that the event can be triggered. Introduced in Windows PowerShell 3.0.

System_CAPS_pubmethodSubscribeEvent(Object, String, String, PSObject, ScriptBlock, Boolean, Boolean)

When overridden in a derived class, creates a subscriber to an event and specifies the script block that is run when the event is triggered. This method is introduced in Windows PowerShell 2.0.

System_CAPS_pubmethodSubscribeEvent(Object, String, String, PSObject, ScriptBlock, Boolean, Boolean, Int32)

When overridden in a derived class, creates a subscriber to an event, specifies the script block that is run when the event is triggered, and specifies the maximum number of times that the event can be triggered. Introduced in Windows PowerShell 3.0.

System_CAPS_pubmethodToString()

(Inherited from Object.)

System_CAPS_pubmethodUnsubscribeEvent(PSEventSubscriber)

When overridden in a derived class, removes a subscriber from the list of objects that subscribe to the event. This method is introduced in Windows PowerShell 2.0.

The event manager can be accessed through the following properties.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show:
© 2016 Microsoft