PipelineBuffer.GetBlobData(Int32, Int32, Int32) 메서드

정의

PipelineBuffer 열에 저장된 BLOB(Binary Large Object)에서 바이트 배열을 검색합니다.

public:
 cli::array <System::Byte> ^ GetBlobData(int columnIndex, int offset, int count);
public byte[] GetBlobData (int columnIndex, int offset, int count);
member this.GetBlobData : int * int * int -> byte[]
Public Function GetBlobData (columnIndex As Integer, offset As Integer, count As Integer) As Byte()

매개 변수

columnIndex
Int32

BLOB이 포함된 열의 인덱스입니다.

offset
Int32

BLOB에서 바이트 검색을 시작할 지점입니다.

count
Int32

BLOB에서 검색할 바이트 수입니다.

반환

Byte[]

PipelineBuffer 열의 바이트 배열입니다.

예제

다음 예제에서는 열에서 바이트의 전체 배열을 검색합니다 PipelineBuffer .

public override void ProcessInput(int inputID, PipelineBuffer buffer)  
{  
   IDTSInput100 input = ComponentMetaData.InputCollection.GetObjectByID(inputID);  

   foreach (IDTSInputColumn100 col in input.InputColumnCollection)  
   {  
      int index = BufferManager.FindColumnByLineageID(input.Buffer, col.LineageID);  
      BufferColumn bc = buffer.GetColumnInfo(index);  

      if (bc.DataType == DataType.DT_IMAGE)  
      {  
         uint blobLength =  buffer.GetBlobLength(index);  
         byte [] blobBytes = buffer.GetBlobData(index, 0, (int)blobLength);  

         //TODO: Do something with the blob data.  

      }  
   }  
}  
Public  Overrides Sub ProcessInput(ByVal inputID As Integer, ByVal buffer As PipelineBuffer)   
 Dim input As IDTSInput100 = ComponentMetaData.InputCollection.GetObjectByID(inputID)   
 For Each col As IDTSInputColumn100 In input.InputColumnCollection   
   Dim index As Integer = BufferManager.FindColumnByLineageID(input.Buffer, col.LineageID)   
   Dim bc As BufferColumn = buffer.GetColumnInfo(index)   
   If bc.DataType = DataType.DT_IMAGE Then   
     Dim blobLength As System.UInt32 = buffer.GetBlobLength(index)   
     Dim blobBytes As Byte() = buffer.GetBlobData(index, 0, CType(blobLength, Integer))   
     'TODO: Do something with the blob data  
   End If   
 Next   
End Sub  

설명

이 메서드는 다음 Integration Services 데이터 형식에서 작동합니다.

BLOB과 같은 DT_IMAGEBLOB이 포함된 열에서 PipelineBuffer 데이터를 검색할 때 매개 변수를 offset 사용하여 BLOB의 시작 위치와 매개 변수에서 count 검색할 바이트 수를 지정합니다.

Integration Services 데이터 형식의 전체 목록과 각 형식에 사용할 클래스의 PipelineBuffer 해당 GetSet 메서드는 Data Flow 데이터 형식 작업(Working with Data Types)을 참조하세요.

적용 대상