ServiceManager.Publish Method
.NET Framework 4
Publishes the given service type, but does not declare an instance. When the service is requested, the Publish service callback will be invoked to create the instance. The callback is invoked only once. After that, the instance it returned is cached.
This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.
| Name | Description | |
|---|---|---|
|
Publish<TServiceType>(TServiceType) | Publishes the given service. After it is published, the service instance remains in the service manager until the editing context is disposed of. |
|
Publish<TServiceType>(PublishServiceCallback<TServiceType>) | Publishes the given service type, but does not declare an instance yet. When the service is requested, the PublishServiceCallback will be invoked to create the instance. The callback is invoked only once. After that, the instance it returned is cached. |
|
Publish(Type, PublishServiceCallback) | Publishes the specified service type, but does not declare an instance. When the service is requested, the Publish service callback will be invoked to create the instance. The callback is invoked only once. After that, the instance it returned is cached. |
|
Publish(Type, Object) | Publishes the given service. After it is published, the service instance remains in the service manager until the editing context is disposed of. |