Package.GetBreakpointTargets(IDTSBreakpointSite, Boolean) 메서드

정의

BreakpointTargets 컬렉션을 반환합니다. onlyEnabled 매개 변수의 설정에 따라 컬렉션은 패키지의 모든 중단점 대상을 포함하거나 사용 가능한 중단점 대상만 포함합니다.

public:
 Microsoft::SqlServer::Dts::Runtime::BreakpointTargets ^ GetBreakpointTargets(Microsoft::SqlServer::Dts::Runtime::IDTSBreakpointSite ^ bpSite, bool onlyEnabled);
public Microsoft.SqlServer.Dts.Runtime.BreakpointTargets GetBreakpointTargets (Microsoft.SqlServer.Dts.Runtime.IDTSBreakpointSite bpSite, bool onlyEnabled);
member this.GetBreakpointTargets : Microsoft.SqlServer.Dts.Runtime.IDTSBreakpointSite * bool -> Microsoft.SqlServer.Dts.Runtime.BreakpointTargets
Public Function GetBreakpointTargets (bpSite As IDTSBreakpointSite, onlyEnabled As Boolean) As BreakpointTargets

매개 변수

bpSite
IDTSBreakpointSite

IDTSBreakpointSite 인터페이스를 구현하는 개체입니다.

onlyEnabled
Boolean

컬렉션에 포함할 중단점 대상의 유형을 나타내는 부울입니다. true는 사용 가능한 중단점만 컬렉션에 포함됨을 나타내고, false는 모든 중단점 대상이 컬렉션에 포함되어 있음을 나타냅니다.

반환

BreakpointTargets

BreakpointTargets 컬렉션입니다.

예제

다음 코드 샘플에서는 패키지에서 GetBreakpointTargets 중단점 컬렉션을 가져오는 방법을 보여 줍니다.

using System;  
using System.Collections.Generic;  
using System.Text;  
using Microsoft.SqlServer.Dts.Runtime;  
using Microsoft.SqlServer.Dts.Tasks.BulkInsertTask;  

namespace Breakpoint_API  
{  
    class Program  
    {  
        static void Main(string[] args)  
        {  
            Package pkg = new Package();  
            TaskHost taskHost = (TaskHost)pkg.Executables.Add("STOCK:FileSystemTask");  
            BreakpointTargets bptargets = pkg.GetBreakpointTargets(taskHost, false);  
            foreach (BreakpointTarget bpt in bptargets)  
            {  
                Console.WriteLine("BreakOnExpressionChange? {0}", bpt.BreakOnExpressionChange.ToString());  
                Console.WriteLine("Description              {0}", bpt.Description);  
                Console.WriteLine("Enabled?                 {0}", bpt.Enabled);  
                Console.WriteLine("HitCount                 {0}", bpt.HitCount);  
                Console.WriteLine("HitTarget                {0}", bpt.HitTarget);  
                Console.WriteLine("HitTest                  {0}", bpt.HitTest);  
                Console.WriteLine("ID                       {0}", bpt.ID);  
                Console.WriteLine("Owner                    {0}", bpt.Owner);  
            }  
        }  
    }  
}  
Imports System  
Imports System.Collections.Generic  
Imports System.Text  
Imports Microsoft.SqlServer.Dts.Runtime  
Imports Microsoft.SqlServer.Dts.Tasks.BulkInsertTask  

Namespace Breakpoint_API  
    Class Program  
        Shared  Sub Main(ByVal args() As String)  
            Dim pkg As Package =  New Package()   
            Dim taskHost As TaskHost = CType(pkg.Executables.Add("STOCK:FileSystemTask"), TaskHost)  
            Dim bptargets As BreakpointTargets =  pkg.GetBreakpointTargets(taskHost,False)   
            Dim bpt As BreakpointTarget  
            For Each bpt In bptargets  
                Console.WriteLine("BreakOnExpressionChange? {0}", bpt.BreakOnExpressionChange.ToString())  
                Console.WriteLine("Description              {0}", bpt.Description)  
                Console.WriteLine("Enabled?                 {0}", bpt.Enabled)  
                Console.WriteLine("HitCount                 {0}", bpt.HitCount)  
                Console.WriteLine("HitTarget                {0}", bpt.HitTarget)  
                Console.WriteLine("HitTest                  {0}", bpt.HitTest)  
                Console.WriteLine("ID                       {0}", bpt.ID)  
                Console.WriteLine("Owner                    {0}", bpt.Owner)  
            Next  
        End Sub  
    End Class  
End Namespace  

샘플 출력:

BreakOnExpressionChange? False

Description Break when the container receives the OnPreExecute event

Enabled? False

HitCount 0

HitTarget 0

HitTest Always

ID -2147483647

Owner Microsoft.SqlServer.Dts.Runtime.TaskHost

설명

true로 설정된 유일한 매개 변수는 속성 값을 Enabled 확인하고 설정된 중단점을 Enabledtrue포함합니다.

Integration Services(SSIS)는 컨테이너 및 작업에 대한 중단점을 지원합니다. SSDT(SQL Server Data Tools)는 디버그 창을 제공하며, SSIS 디자이너는 패키지 제어 흐름을 디버깅하기 위한 진행률 보고를 제공합니다. SSIS 디자이너는 중단점을 사용하도록 설정하고 런타임 엔진이 실행을 중지하기 전에 중단점이 발생하는 횟수를 설정할 수 있는 중단점 설정 대화 상자를 제공합니다. 작업 중단점을 사용하도록 설정하면 제어 흐름 창의 디자인 화면에서 작업 옆에 중단점 아이콘이 나타납니다. 이벤트에 대해 중단점이 발생하도록 설정할 수 있습니다. 이벤트에 중단점을 설정하는 방법에 대한 자세한 내용은 Integration Services(SSIS) 이벤트 처리기를 참조하세요.

적용 대상