共用方式為


SfcInstance Class

Definition

The base class for all Sfc object types in a domain.

public abstract class SfcInstance : Microsoft.SqlServer.Management.Sdk.Sfc.ISfcDiscoverObject, Microsoft.SqlServer.Management.Sdk.Sfc.ISfcPropertyProvider, System.ComponentModel.INotifyPropertyChanged
type SfcInstance = class
    interface ISfcDiscoverObject
    interface ISfcPropertyProvider
    interface ISfcNotifyPropertyMetadataChanged
    interface INotifyPropertyChanged
Public MustInherit Class SfcInstance
Implements INotifyPropertyChanged, ISfcDiscoverObject, ISfcPropertyProvider
Inheritance
SfcInstance
Derived
Implements

Constructors

SfcInstance()

Properties

AbstractIdentityKey
KeyChain

Returns the identity path of the object

Metadata
Parent

Parent is not something that is kept local, it is implied from the keychain The concept of a parent is really about the hiearchy up and under the root if we only do this via parents then we will not be able to instantiate objects with only lightweight SfcKeyChain sets

Setting the parent is therefor a helper operation to set a keychain

Properties
PropertyStorageProvider

This property returns the default implementation of SFC for ISfcPropertyStorageProvider interface, it can be overriden in the child classes to return another storage provider (i.e. flat properties list)

State
Urn

Create a new Urn string on each request and return it.

Methods

AlterImpl()
CheckObjectCreated()

To be called from domain for when an API requires the object to be Created Stronger than CheckObjectState

CheckObjectState()

To be called from domain for any access to the object

CreateIdentityKey()
CreateImpl()
Discover(ISfcDependencyDiscoveryObjectSink)
DropImpl()
GetChildCollection(String)

Get the child collection in this instance for the given element name string.

GetDomain()
GetPropertySet()
GetTypeMetadataImpl()
InitializeUIPropertyState()

Overridable from the child objects who care about initializing their states (dynamic metadata which is currently the ".Enabled" property)

MarkForDropImpl(Boolean)
MarkRootAsConnected()
MoveImpl(SfcInstance)
OnPropertyMetadataChanges(SfcPropertyMetadataChangedEventArgs)
OnPropertyValueChanges(PropertyChangedEventArgs)
PostAlter(Object)
PostCreate(Object)
PostDrop(Object)
PostMove(Object)
PostRename(Object)
Refresh()

refreshes the object's properties by reading them from the server

RenameImpl(SfcKey)
ResetKey()
Serialize(XmlWriter)
ToString()
UpdateUIPropertyState()
Validate()

Basic child object's validation

Events

propertyChanged
PropertyChanged
propertyMetadataChanged
PropertyMetadataChanged

Applies to