Export (0) Print
Expand All

SqlSmoObject Class

The SqlSmoObject object represents all SQL Server objects.

Object
  Microsoft.SqlServer.Management.Smo.SmoObjectBase
    Microsoft.SqlServer.Management.Smo.SqlSmoObject
      More...

Namespace:  Microsoft.SqlServer.Management.Smo
Assembly:  Microsoft.SqlServer.Smo (in Microsoft.SqlServer.Smo.dll)

public abstract class SqlSmoObject extends SmoObjectBase implements ISfcPropertyProvider, ISfcNotifyPropertyMetadataChanged, INotifyPropertyChanged, IRefreshable, IAlienObject

The SqlSmoObject type exposes the following members.

  NameDescription
Protected methodSqlSmoObjectInitializes a new instance of the SqlSmoObject class.
Top

  NameDescription
Protected propertyExecuteForScalarGets or sets the Boolean property value that specifies whether the object is set to the execute for scalar option.
Protected propertyIsTouchedGets the Boolean property value that specifies whether the object properties have been updated but not yet persisted on the server.
Protected propertyObjectInSpaceGets the Boolean property value that specifies whether the object exists in isolation, or whether it is directly or indirectly connected to the instance of SQL Server.
Public propertyPropertiesGets a collection of Property objects that represent the object properties.
Protected propertyScalarResultGets the scalar result for the referenced object.
Public propertyStateGets the state of the referenced object. (Inherited from SmoObjectBase.)
Public propertyUrnGets the Uniform Resource Name (URN) address value that uniquely identifies the object.
Public propertyUserDataGets or sets user-defined data associated with the referenced object. (Inherited from SmoObjectBase.)
Top

  NameDescription
Protected methodAddDatabaseContextAdd the database context to the collection of queries identified by the queries parameter.
Protected methodAlterImplActivates the object altered event.
Protected methodAlterImplWorkerCalls the Alter methods.
Protected methodBindDefaultImplBinds the default items identified by the parameters.
Protected methodBindRuleImplBinds the rule schema to the rule and columns identified by the parameters.
Protected methodCheckObjectState()Validates the state of the referenced object.
Protected methodCheckObjectState(Boolean)Validates the state of the referenced object with the option to specify that an exception is thrown if the object is not yet created.
Protected methodCheckObjectStateImplChecks the state of a SqlSmoObject.
Protected methodCheckVersion100Checks whether version of SQL Server is SQL Server 2008.
Protected methodCheckVersion110()Checks whether version of SQL Server is SQL Server 2012.
Protected methodCheckVersion110(String)Checks whether the version of SQL Server is SQL Server 2012 with the specified name.
Protected methodCheckVersion120()Checks whether the version of SQL Server is .
Protected methodCheckVersion120(String)Checks whether the version of SQL Server is .
Protected methodCheckVersion80Checks the validity of the object on SQL Server 2000.
Protected methodCheckVersion80SP3Checks the validity of the object on SQL Server 2000 SP3.
Protected methodCheckVersion90Check the validity of the object on SQL Server 2005.
Protected methodCheckVersionBelow110Checks whether version of SQL Server is before SQL Server 2012.
Protected methodCheckVersionBelow90Checks whether version of SQL Server is before SQL Server 2005.
Protected methodCleanObjectSets the object to its unmodified state.
Protected methodCreateImplCreates an object with scripting options.
Public methodDiscoverDiscovers a list of type Object.
Protected methodDropImplDrops a SqlSmoObject.
Protected methodDropImplWorkerCalls the drop methods.
Public methodEquals (Inherited from Object.)
Protected methodExecuteNonQueryExecutes a batch of statements that does not return a result set.
Protected methodFinalize (Inherited from Object.)
Protected methodFormatSqlVariantFormats an object as SqlVariant type.
Protected methodGenerateAlterEvent()Generates the alter event with the specified value.
Protected methodGenerateAlterEvent(Urn, Object)Generates alter event with the specified URN and inner object value.
Public methodStatic memberGetChildTypeGets the type of a child element.
Protected methodGetContextDBGets the context database that is associated with this object.
Protected methodGetDBNameGets the database name that is associated with the object.
Protected methodGetFragOptionStringGets a FragmentationOption object as a string value.
Public methodGetHashCode (Inherited from Object.)
Protected methodGetPropValueGets a property value of the SqlSmoObject object.
Protected methodGetPropValueOptionalGets a property value of the SqlSmoObject object.
Protected methodGetPropValueOptionalAllowNullGets a property value of the SqlSmoObject object.
Protected methodGetRealValueGets a property value of the SqlSmoObject object.
Protected methodGetServerNameGets the name of the instance of SQL Server with which the object is associated.
Protected methodGetServerObjectGets the server of the SqlSmoObject object.
Protected methodGetSqlServerVersionNameGets the version name of the instance of SQL Server with which the object is associated.
Public methodGetType (Inherited from Object.)
Public methodStatic memberGetTypeFromUrnSkeletonGets the type from the Urn object specified by the parameter.
Protected methodGetUrnRecursive(StringBuilder)Assigns an Urn object of the SqlSmoObject object.
Protected methodGetUrnRecursive(StringBuilder, UrnIdOption)Assigns an Urn object of the SqlSmoObject object.
Protected methodImplInitializeInitializes the fields of the SqlSmoObject object.
Public methodInitialize()Initializes the object and forces the properties be loaded.
Public methodInitialize(Boolean)Initializes the object and forces the properties be loaded.
Protected methodStatic memberIsCollectionDirtyDetermines whether any object in the SqlSmoObject collection has been modified.
Protected methodIsObjectDirtyVerifies whether the object properties have been modified and the changes have not yet been persisted on the instance of SQL Server.
Protected methodIsObjectInitializedVerifies whether the object has been initialized.
Protected methodIsObjectInSpaceVerifies whether the object is isolated or connected to the instance of SQL Server.
Protected methodIsVersion80SP3Determines whether the version of SQL Server is SQL Server 2000 with SP3.
Protected methodIsVersion90AndAboveDetermines whether the version of SQL Server is SQL Server 2005 or later.
Protected methodMarkDroppedSets the SqlSmoState to dropped.
Protected methodMarkForDropImplSets the SqlSmoState for drop operation.
Protected methodMemberwiseClone (Inherited from Object.)
Protected methodPostAlterThe method that is activated after the SqlSmoObject is altered.
Protected methodPostCreateThe method that is activated after the SqlSmoObject is created.
Protected methodPostDropThe method that is activated after the SqlSmoObject is dropped.
Public methodRefreshRefreshes the object and retrieves properties when the object is next accessed.
Protected methodScriptImpl()Gets a collection of scripts of the SqlSmoObject.
Protected methodScriptImpl(ScriptingOptions)Gets a collection of scripts of the SqlSmoObject.
Protected methodSetParentImplSets the parent of the SqlSmoObject to the newParent parameter.
Public methodToStringReturns a String that represents the referenced object. (Overrides ObjectToString.)
Protected methodTouchImplNot implemented.
Protected methodStatic memberTraceTraces the object.
Protected methodUnbindDefaultImplUnbinds the default columns of the SqlSmoObject.
Protected methodUnbindRuleImplUnbinds rules of the SqlSmoObject.
Protected methodStatic memberUpdateCollectionState2Updates the collection state of the SqlSmoObject.
Public methodValidateValidates the state of an object. (Inherited from SmoObjectBase.)
Top

  NameDescription
Public eventPropertyChangedRepresents the event that occurs when a property is changed.
Public eventPropertyMetadataChangedRepresents the event that occurs when property metadata changes.
Top

  NameDescription
Protected fieldm_ExtendedPropertiesRepresents a property that is defined to extend the properties provided by a SqlSmoObject.
Protected fieldsingletonParentRepresents the singleton parent.
Top

  NameDescription
Explicit interface implemetationPrivate methodIAlienObject.DiscoverDiscovers any dependencies. Do not reference this member directly in your code. It supports the SQL Server infrastructure.
Explicit interface implemetationPrivate methodIAlienObject.GetDomainRootReturns the root of the domain.
Explicit interface implemetationPrivate methodIAlienObject.GetParentGets the parent of this object. Do not reference this member directly in your code. It supports the SQL Server infrastructure.
Explicit interface implemetationPrivate methodIAlienObject.GetPropertyTypeGets the type of the specified property.
Explicit interface implemetationPrivate methodIAlienObject.GetPropertyValueGets the value of the specified property.
Explicit interface implemetationPrivate methodIAlienObject.GetUrnGets the Unified Resource Name (URN) of the object. Do not reference this member directly in your code. It supports the SQL Server infrastructure.
Explicit interface implemetationPrivate methodIAlienObject.ResolveGets the instance that contains the information about the object from the Unified Resource Name (URN) of the object.
Explicit interface implemetationPrivate methodIAlienObject.SetObjectStateSets the object state to the specified SfcObjectState value.
Explicit interface implemetationPrivate methodIAlienObject.SetPropertyValueSets the property value.
Explicit interface implemetationPrivate methodISfcPropertyProvider.GetPropertySetGets the interface reference to the set of properties of this object.
Top

The SqlSmoObject is a generic object that is used to referenced objects that are not of a specified type. The SqlSmoObject is also used as a base class.

Thread Safety

Any public static (Shared in Microsoft Visual Basic) members of this type are safe for multithreaded operations. Any instance members are not guaranteed to be thread safe.  

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Object
  Microsoft.SqlServer.Management.Smo.SmoObjectBase
    Microsoft.SqlServer.Management.Smo.SqlSmoObject
      Microsoft.SqlServer.Management.Smo.Agent.JobServer
      Microsoft.SqlServer.Management.Smo.AvailabilityGroupListenerIPAddress
      Microsoft.SqlServer.Management.Smo.Broker.ServiceBroker
      Microsoft.SqlServer.Management.Smo.DatabaseActiveDirectory
      Microsoft.SqlServer.Management.Smo.DatabaseEncryptionKey
      Microsoft.SqlServer.Management.Smo.DatabaseOptions
      Microsoft.SqlServer.Management.Smo.DatabaseReplicaState
      Microsoft.SqlServer.Management.Smo.DatabaseSegment
      Microsoft.SqlServer.Management.Smo.EndpointPayload
      Microsoft.SqlServer.Management.Smo.EndpointProtocol
      Microsoft.SqlServer.Management.Smo.FileSegment
      Microsoft.SqlServer.Management.Smo.FullTextIndex
      Microsoft.SqlServer.Management.Smo.Information
      Microsoft.SqlServer.Management.Smo.Mail.SqlMail
      Microsoft.SqlServer.Management.Smo.MasterKey
      Microsoft.SqlServer.Management.Smo.MessageObjectBase
      Microsoft.SqlServer.Management.Smo.NamedSmoObject
      Microsoft.SqlServer.Management.Smo.PhysicalPartition
      Microsoft.SqlServer.Management.Smo.ResourceGovernor
      Microsoft.SqlServer.Management.Smo.Server
      Microsoft.SqlServer.Management.Smo.ServerActiveDirectory
      Microsoft.SqlServer.Management.Smo.ServerProxyAccount
      Microsoft.SqlServer.Management.Smo.ServiceMasterKey
      Microsoft.SqlServer.Management.Smo.Settings
      Microsoft.SqlServer.Management.Smo.SmartAdmin
      Microsoft.SqlServer.Management.Smo.UserOptions
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft