다음을 통해 공유


DiscoveryClientResultCollection.Item[Int32] 속성

정의

DiscoveryClientResulti 위치에 있는 DiscoveryClientResultCollection를 가져오거나 설정합니다.

public:
 property System::Web::Services::Discovery::DiscoveryClientResult ^ default[int] { System::Web::Services::Discovery::DiscoveryClientResult ^ get(int i); void set(int i, System::Web::Services::Discovery::DiscoveryClientResult ^ value); };
public System.Web.Services.Discovery.DiscoveryClientResult this[int i] { get; set; }
member this.Item(int) : System.Web.Services.Discovery.DiscoveryClientResult with get, set
Default Public Property Item(i As Integer) As DiscoveryClientResult

매개 변수

i
Int32

가져오거나 설정할 DiscoveryClientResult의 인덱스(0부터 시작)입니다.

속성 값

DiscoveryClientResult

지정한 인덱스에 있는 DiscoveryClientResult입니다.

예외

iDiscoveryClientResultCollection의 유효한 인덱스가 아닌 경우

예제

for ( int i = 0; i < myDiscoveryClientResultCollection->Count; i++ )
{
   DiscoveryClientResult^ myClientResult = myDiscoveryClientResultCollection[ i ];
   Console::WriteLine( "DiscoveryClientResult {0}", (i + 1) );
   Console::WriteLine( "Type of reference in the discovery document: {0}", myClientResult->ReferenceTypeName );
   Console::WriteLine( "Url for reference:{0}", myClientResult->Url );
   Console::WriteLine( "File for saving the reference: {0}", myClientResult->Filename );
}
for(int i=0; i<myDiscoveryClientResultCollection.Count; i++)
{
   DiscoveryClientResult myClientResult =
       myDiscoveryClientResultCollection[i];
   Console.WriteLine("DiscoveryClientResult "+(i+1));
   Console.WriteLine("Type of reference in the discovery document: "
       + myClientResult.ReferenceTypeName);
   Console.WriteLine("Url for reference:" + myClientResult.Url);
   Console.WriteLine("File for saving the reference: "
       + myClientResult.Filename);
}
Dim i As Integer
For i = 0 To myDiscoveryClientResultCollection.Count - 1
   Dim myClientResult As DiscoveryClientResult = _
       myDiscoveryClientResultCollection(i)
   Console.WriteLine("DiscoveryClientResult " & (i + 1).ToString())
   Console.WriteLine("Type of reference in the discovery document: " _
       & myClientResult.ReferenceTypeName)
   Console.WriteLine("Url for reference:" & myClientResult.Url)
   Console.WriteLine("File for saving the reference: " _
       & myClientResult.Filename)
Next i

설명

이 속성은 myCollection[index] 구문을 사용하여 컬렉션의 특정 요소에 액세스하는 기능을 제공합니다.

적용 대상