TSqlModel.GetObject(ModelTypeClass, ObjectIdentifier, DacQueryScopes) TSqlModel.GetObject(ModelTypeClass, ObjectIdentifier, DacQueryScopes) TSqlModel.GetObject(ModelTypeClass, ObjectIdentifier, DacQueryScopes) Method

Definition

Returns TSqlObjects of the specified objectType and id. Only top level ModelTypeClass types are supported by this method - the objectType parameter must be in the types returned from the TopLevelTypes method or the call will fail.

public Microsoft.SqlServer.Dac.Model.TSqlObject GetObject (Microsoft.SqlServer.Dac.Model.ModelTypeClass objectType, Microsoft.SqlServer.Dac.Model.ObjectIdentifier id, Microsoft.SqlServer.Dac.Model.DacQueryScopes queryScopes);
member this.GetObject : Microsoft.SqlServer.Dac.Model.ModelTypeClass * Microsoft.SqlServer.Dac.Model.ObjectIdentifier * Microsoft.SqlServer.Dac.Model.DacQueryScopes -> Microsoft.SqlServer.Dac.Model.TSqlObject
Public Function GetObject (objectType As ModelTypeClass, id As ObjectIdentifier, queryScopes As DacQueryScopes) As TSqlObject

Parameters

objectType
ModelTypeClass ModelTypeClass ModelTypeClass

Type filter. Must be in the list of ModelTypeClass types returned from the TopLevelTypes method or the call will fail.

queryScopes
DacQueryScopes DacQueryScopes DacQueryScopes

Scope filter for queried objects.

Returns

Single TSqlObject or null.

Exceptions

If the supplied objectType and id result in multiple TSqlObjects, or if the objectType is not a top level type.

If communication with the Microsoft.SqlServer.Dac.Model.TSqlObjectService fails.

Applies to