ServiceManager.Publish Method (Type, Object)

When overridden in a derived class, publishes the specified service instance of the specified type.

Namespace:  Microsoft.Windows.Design
Assembly:  Microsoft.Windows.Design.Extensibility (in Microsoft.Windows.Design.Extensibility.dll)

Syntax

'Declaration
Public MustOverride Sub Publish ( _
    serviceType As Type, _
    serviceInstance As Object _
)
public abstract void Publish(
    Type serviceType,
    Object serviceInstance
)
public:
virtual void Publish(
    Type^ serviceType, 
    Object^ serviceInstance
) abstract
abstract Publish : 
        serviceType:Type * 
        serviceInstance:Object -> unit 
public abstract function Publish(
    serviceType : Type, 
    serviceInstance : Object
)

Parameters

  • serviceType
    Type: System.Type
    The type of service that is being published.
  • serviceInstance
    Type: System.Object
    An instance of the service.

Remarks

Once the service is created in an EditingContext it is always present. A service cannot be removed from the EditingContext.

.NET Framework Security

See Also

Reference

ServiceManager Class

Publish Overload

Microsoft.Windows.Design Namespace

EditingContext

ContextItem

Unsubscribe

Subscribe

Other Resources

WPF Designer Extensibility