ImportCollection.Add(Import) Metoda

Definice

Přidá zadanou Import hodnotu na konec ImportCollection.

public:
 int Add(System::Web::Services::Description::Import ^ import);
public int Add(System.Web.Services.Description.Import import);
member this.Add : System.Web.Services.Description.Import -> int
Public Function Add (import As Import) As Integer

Parametry

import
Import

Přidání Import do kolekce.

Návraty

Index založený na nule, do kterého import byl parametr přidán.

Příklady

Následující příklad ukazuje použití Add metody. Další informace o CreateImport metodě použité v ukázce najdete v příkladu Import pod třídou.

ServiceDescription^ myServiceDescription = ServiceDescription::Read( "StockQuote_cpp.wsdl" );
myServiceDescription->Imports->Add( CreateImport( "http://localhost/stockquote/schemas", "http://localhost/stockquote/stockquote_cpp.xsd" ) );
ServiceDescription myServiceDescription =
   ServiceDescription.Read("StockQuote_cs.wsdl");
myServiceDescription.Imports.Add(
   CreateImport("http://localhost/stockquote/schemas",
   "http://localhost/stockquote/stockquote_cs.xsd"));
Dim myServiceDescription As ServiceDescription = _
   ServiceDescription.Read("StockQuote_vb.wsdl")
myServiceDescription.Imports.Add( _
   CreateImport("http://localhost/stockquote/schemas", _
   "http://localhost/stockquote/stockquote_vb.xsd"))

Platí pro