ServiceProviders.AddService(Type, Object) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Ajoute un service à la liste.
public:
void AddService(Type ^ serviceType, System::Object ^ service);
public void AddService(Type serviceType, object service);
member this.AddService : Type * obj -> unit
Public Sub AddService (serviceType As Type, service As Object)
Paramètres
- serviceType
- Type
Type de service du nouveau service.
- service
- Object
Classe d'implémentation du service.
Exceptions
serviceType ou service est null.
Tentative d'ajout d'un service qui existe déjà dans le dictionnaire.