C# 클래스 PsmFramework.Engines.Messaging.WeakAction

Stores an Action without causing a hard reference to be created to the Action's owner. The owner can be garbage collected at any time.
파일 보기 프로젝트 열기: artwallace/PsmFramework

공개 메소드들

메소드 설명
Execute ( ) : void

Executes the action. This only happens if the action's owner is still alive.

MarkForDeletion ( ) : void

Sets the reference that this instance stores to null.

WeakAction ( object target, System.Action action ) : System

Initializes a new instance of the WeakAction class.

메소드 상세

Execute() 공개 메소드

Executes the action. This only happens if the action's owner is still alive.
public Execute ( ) : void
리턴 void

MarkForDeletion() 공개 메소드

Sets the reference that this instance stores to null.
public MarkForDeletion ( ) : void
리턴 void

WeakAction() 공개 메소드

Initializes a new instance of the WeakAction class.
public WeakAction ( object target, System.Action action ) : System
target object The action's owner.
action System.Action The action that will be associated to this instance.
리턴 System