Hinweis
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, sich anzumelden oder das Verzeichnis zu wechseln.
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, das Verzeichnis zu wechseln.
Fügt der OperationBindingCollection die angegebene OperationBinding-Instanz am angegebenen nullbasierten Index hinzu.
Namespace: System.Web.Services.Description
Assembly: System.Web.Services (in system.web.services.dll)
Syntax
'Declaration
Public Sub Insert ( _
index As Integer, _
bindingOperation As OperationBinding _
)
'Usage
Dim instance As OperationBindingCollection
Dim index As Integer
Dim bindingOperation As OperationBinding
instance.Insert(index, bindingOperation)
public void Insert (
int index,
OperationBinding bindingOperation
)
public:
void Insert (
int index,
OperationBinding^ bindingOperation
)
public void Insert (
int index,
OperationBinding bindingOperation
)
public function Insert (
index : int,
bindingOperation : OperationBinding
)
Parameter
- index
Der nullbasierte Index, an dem der bindingOperation-Parameter eingefügt werden soll.
- bindingOperation
Das der Auflistung hinzuzufügende OperationBinding.
Hinweise
Wenn die Anzahl der Elemente in der Auflistung bereits der Kapazität der Auflistung entspricht, wird diese verdoppelt, indem das interne Array vor dem Einfügen des neuen Elements automatisch neu reserviert wird.
Wenn der index-Parameter gleich Count ist, wird der bindingOperation-Parameter am Ende der OperationBindingCollection hinzugefügt.
Die Elemente nach der Einfügemarke werden nach unten verschoben, um das neue Element aufnehmen zu können.
Beispiel
Im folgenden Beispiel wird die Verwendung der Insert-Methode veranschaulicht.
' Insert the OperationBinding of the Add operation at index 0.
myOperationBindingCollection.Insert(0, addOperationBinding)
Console.WriteLine(ControlChars.NewLine & _
"Inserted the OperationBinding of the " & _
"Add operation in the collection.")
' Get the index of the OperationBinding of the Add
' operation from the collection.
Dim index As Integer = myOperationBindingCollection.IndexOf( _
addOperationBinding)
Console.WriteLine(ControlChars.NewLine & _
"The index of the OperationBinding of the " & _
"Add operation : " & index.ToString())
// Insert the OperationBinding of the Add operation at index 0.
myOperationBindingCollection.Insert(0, addOperationBinding);
Console.WriteLine("\nInserted the OperationBinding of the " +
"Add operation in the collection.");
// Get the index of the OperationBinding of the Add
// operation from the collection.
int index = myOperationBindingCollection.IndexOf(addOperationBinding);
Console.WriteLine("\nThe index of the OperationBinding of the " +
"Add operation : " + index);
// Insert the OperationBinding of the Add operation at index 0.
myOperationBindingCollection->Insert( 0, addOperationBinding );
Console::WriteLine( "\nInserted the OperationBinding of the "
"Add operation in the collection." );
// Get the index of the OperationBinding of the Add
// operation from the collection.
int index = myOperationBindingCollection->IndexOf( addOperationBinding );
Console::WriteLine( "\nThe index of the OperationBinding of the Add operation : {0}", index );
// Insert the OperationBinding of the Add operation at index 0.
myOperationBindingCollection.Insert(0, addOperationBinding);
Console.WriteLine("\nInserted the OperationBinding of the "
+ "Add operation in the collection.");
// Get the index of the OperationBinding of the Add
// operation from the collection.
int index = myOperationBindingCollection.
IndexOf(addOperationBinding);
Console.WriteLine("\nThe index of the OperationBinding of the "
+ "Add operation : " + index);
Plattformen
Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
.NET Framework unterstützt nicht alle Versionen sämtlicher Plattformen. Eine Liste der unterstützten Versionen finden Sie unter Systemanforderungen.
Versionsinformationen
.NET Framework
Unterstützt in: 2.0, 1.1, 1.0
Siehe auch
Referenz
OperationBindingCollection-Klasse
OperationBindingCollection-Member
System.Web.Services.Description-Namespace