OperationMessageCollection.Remove(OperationMessage) 메서드

정의

에서 지정된 OperationMessageOperationMessageCollection첫 번째 항목을 제거합니다.

public:
 void Remove(System::Web::Services::Description::OperationMessage ^ operationMessage);
public void Remove(System.Web.Services.Description.OperationMessage operationMessage);
member this.Remove : System.Web.Services.Description.OperationMessage -> unit
Public Sub Remove (operationMessage As OperationMessage)

매개 변수

operationMessage
OperationMessage

OperationMessage 컬렉션에서 제거할 항목입니다.

예제

myOperationMessageCollection->Remove( myInputOperationMessage );

// Display Flow, Input, and Output after removing.
DisplayFlowInputOutput( myOperationMessageCollection, "Remove" );

// Insert the message at index 0 in the collection.
myOperationMessageCollection->Insert( 0, myInputOperationMessage );

// Display Flow, Input, and Output after inserting.
DisplayFlowInputOutput( myOperationMessageCollection, "Insert" );
myOperationMessageCollection.Remove(myInputOperationMessage);

// Display Flow, Input, and Output after removing.
DisplayFlowInputOutput(myOperationMessageCollection, "Remove");

// Insert the message at index 0 in the collection.
myOperationMessageCollection.Insert(0, myInputOperationMessage);

// Display Flow, Input, and Output after inserting.
DisplayFlowInputOutput(myOperationMessageCollection, "Insert");
myOperationMessageCollection.Remove(myInputOperationMessage)

' Display Flow, Input, and Output after removing.
DisplayFlowInputOutput(myOperationMessageCollection, "Remove")

' Insert the message at index 0 in the collection.
myOperationMessageCollection.Insert(0, myInputOperationMessage)

' Display Flow, Input, and Output after inserting.
DisplayFlowInputOutput(myOperationMessageCollection, "Insert")

설명

이 메서드는 선형 검색을 수행합니다. 따라서 평균 실행 시간은 .에 비례합니다 Count.

제거된 OperationMessage 뒤에 있는 요소가 위로 이동하여 비워진 지점을 차지합니다.

적용 대상