ServiceDescriptionFormatExtensionCollection.FindAll メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
渡されたパラメーターで指定されたコレクションのすべてのメンバーについて、 ServiceDescriptionFormatExtensionCollection を検索します。
オーバーロード
| 名前 | 説明 |
|---|---|
| FindAll(Type) |
ServiceDescriptionFormatExtensionCollectionを検索し、指定したTypeのすべての要素の配列を返します。 |
| FindAll(String, String) |
ServiceDescriptionFormatExtensionCollectionを検索し、指定した名前と名前空間 URI を持つすべてのメンバーの配列を返します。 |
FindAll(Type)
ServiceDescriptionFormatExtensionCollectionを検索し、指定したTypeのすべての要素の配列を返します。
public:
cli::array <System::Object ^> ^ FindAll(Type ^ type);
public object[] FindAll(Type type);
member this.FindAll : Type -> obj[]
Public Function FindAll (type As Type) As Object()
パラメーター
返品
指定した型のすべてのコレクション メンバーを表す Object インスタンスの配列。
例
// Check all elements of type 'SoapBinding' in collection.
array<Object^>^myObjectArray1 = gcnew array<Object^>(myCollection->Count);
myObjectArray1 = myCollection->FindAll( mySoapBinding1->GetType() );
int myNumberOfElements = 0;
IEnumerator^ myIEnumerator = myObjectArray1->GetEnumerator();
// Calculate number of elements of type 'SoapBinding'.
while ( myIEnumerator->MoveNext() )
if ( mySoapBinding1->GetType() == myIEnumerator->Current->GetType() )
myNumberOfElements++;
Console::WriteLine( "Collection contains {0} objects of type ' {1}'.", myNumberOfElements, mySoapBinding1->GetType() );
// Check all elements of type 'SoapBinding' in collection.
Object[] myObjectArray1 = new Object[myCollection.Count];
myObjectArray1 = myCollection.FindAll(mySoapBinding1.GetType());
int myNumberOfElements = 0;
IEnumerator myIEnumerator = myObjectArray1.GetEnumerator();
// Calculate number of elements of type 'SoapBinding'.
while(myIEnumerator.MoveNext())
{
if(mySoapBinding1.GetType() == myIEnumerator.Current.GetType())
myNumberOfElements++;
}
Console.WriteLine("Collection contains {0} objects of type '{1}'.",
myNumberOfElements.ToString(),
mySoapBinding1.GetType().ToString());
' Check all elements of type 'SoapBinding' in collection.
Dim myObjectArray1(myCollection.Count -1 ) As Object
myObjectArray1 = myCollection.FindAll(mySoapBinding1.GetType())
Dim myNumberOfElements As Integer = 0
Dim myIEnumerator As IEnumerator = myObjectArray1.GetEnumerator()
' Calculate number of elements of type 'SoapBinding'.
While myIEnumerator.MoveNext()
If mySoapBinding1.GetType() Is myIEnumerator.Current.GetType() Then
myNumberOfElements += 1
End If
End While
Console.WriteLine("Collection contains {0} objects of type '{1}'.", _
myNumberOfElements.ToString(), mySoapBinding1.GetType().ToString())
注釈
Note
検索が失敗した場合、返される配列は空です。
適用対象
FindAll(String, String)
ServiceDescriptionFormatExtensionCollectionを検索し、指定した名前と名前空間 URI を持つすべてのメンバーの配列を返します。
public:
cli::array <System::Xml::XmlElement ^> ^ FindAll(System::String ^ name, System::String ^ ns);
public System.Xml.XmlElement[] FindAll(string name, string ns);
member this.FindAll : string * string -> System.Xml.XmlElement[]
Public Function FindAll (name As String, ns As String) As XmlElement()
パラメーター
- name
- String
見つかる XmlElement オブジェクトの XML 名属性。
- ns
- String
検出される XmlElement オブジェクトの XML 名前空間 URI 属性。
返品
XmlElement インスタンスの配列。
注釈
Note
検索が失敗した場合、返される配列は空です。