AddInProcess 클래스

정의

호스트 애플리케이션에서 out-of-process로 추가 기능을 실행하기 위한 외부 프로세스를 제공합니다.

public ref class AddInProcess sealed
public sealed class AddInProcess
type AddInProcess = class
Public NotInheritable Class AddInProcess
상속
AddInProcess

예제

다음 예제에서는 외부 프로세스에서 추가 기능을 활성화합니다.

// Create an external process.
AddInProcess pExternal = new AddInProcess();

// Activate an add-in in the external process
// with a full trust security level.
Calculator CalcAddIn4 =
    selectedToken.Activate<Calculator>(pExternal,
    AddInSecurityLevel.FullTrust);

// Show that the add-in is an external process
// by verifying that it is not in the current (host's) process.
AddInController AddinCtl = AddInController.GetAddInController(CalcAddIn4);
Console.WriteLine("Add-in in host's process: {0}",
    AddinCtl.AddInEnvironment.Process.IsCurrentProcess);
' Create an external process.
Dim pExternal As New AddInProcess()

' Activate an add-in in the external process
' with a full trust security level.
Dim CalcAddIn4 As Calculator = _
    selectedToken.Activate(Of Calculator)(pExternal, _
        AddInSecurityLevel.FullTrust)

' Show that the add-in is an external process
' by verifying that it is not in the current (host's) process.
Dim AddinCtl As AddInController = AddInController.GetAddInController(CalcAddIn4)
Console.WriteLine("Add-in in host's process: {0}", _
 AddinCtl.AddInEnvironment.Process.IsCurrentProcess)

설명

외부 프로세스에서 추가 기능을 활성화하려면 개체를 AddInProcess 적절한 AddInToken.Activate<T>(AddInProcess, PermissionSet) 메서드 오버로드에 전달합니다.

추가 기능을 실행하는 실행 파일은 Windows 디렉터리 아래의 .NET Framework 설치된 두 파일 중 하나에서 가져옵니다. 호스트 애플리케이션의 단어당-일치 하는 실행 파일은 기본적으로 사용 됩니다. 호스트가 64비트 프로세스인 경우 AddInProcess.exe 실행됩니다. 그렇지 않으면 AddInProcess32.exe 실행됩니다. 실행 파일을 선택하는 방법을 지정하려면 생성자를 사용하여 AddInProcess(Platform) 개체를 만듭니다 AddInProcess .

생성자

AddInProcess()

AddInProcess 클래스의 새 인스턴스를 초기화합니다.

AddInProcess(Platform)

추가 기능이 실행되는 프로세스의 단어당 비트 수를 지정하는 AddInProcess 클래스의 새 인스턴스를 초기화합니다.

속성

IsCurrentProcess

현재 AddInProcess 개체가 호스트 애플리케이션 프로세스를 나타내는지 여부를 나타내는 값을 가져옵니다.

KeepAlive

외부 프로세스를 활성화 상태로 유지하는지 여부를 나타내는 값을 가져오거나 설정합니다.

Platform

out-of-process 추가 기능이 실행되는 프로세스의 단어당 비트 수를 가져옵니다.

ProcessId

외부 프로세스의 프로세스 ID를 가져옵니다.

StartupTimeout

프로세스가 시작될 수 있는 시간(초)을 가져오거나 설정합니다.

메서드

Equals(Object)

지정된 개체가 현재 개체와 같은지 확인합니다.

(다음에서 상속됨 Object)
GetHashCode()

기본 해시 함수로 작동합니다.

(다음에서 상속됨 Object)
GetType()

현재 인스턴스의 Type을 가져옵니다.

(다음에서 상속됨 Object)
MemberwiseClone()

현재 Object의 단순 복사본을 만듭니다.

(다음에서 상속됨 Object)
Shutdown()

외부 프로세스를 강제로 종료합니다.

Start()

외부 프로세스를 시작합니다.

ToString()

현재 개체를 나타내는 문자열을 반환합니다.

(다음에서 상속됨 Object)

이벤트

ShuttingDown

AddInProcess 개체로 나타나는 프로세스가 종료되려고 할 때 발생합니다.

적용 대상

추가 정보