DacPackage 類別
Representation of the artifact that contains the definition of a data-tier application.
繼承階層
System.Object
Microsoft.SqlServer.Dac.DacPackage
命名空間: Microsoft.SqlServer.Dac
組件: Microsoft.SqlServer.Dac (在 Microsoft.SqlServer.Dac.dll 中)
語法
'宣告
Public NotInheritable Class DacPackage _
Implements IDisposable
'用途
Dim instance As DacPackage
public sealed class DacPackage : IDisposable
public ref class DacPackage sealed : IDisposable
[<SealedAttribute>]
type DacPackage =
class
interface IDisposable
end
public final class DacPackage implements IDisposable
DacPackage 型別公開下列成員。
屬性
名稱 | 說明 | |
---|---|---|
![]() |
Description | Get an optional summary of this package. |
![]() |
Name | Get identifier for this package. |
![]() |
PostDeploymentScript | Get stream used to read and write script executed after deploying schema contained in this package. |
![]() |
PreDeploymentScript | Get stream used to read and write script executed prior to deploying schema contained in this package. |
![]() |
Version | Get version information for this package. |
上層
方法
名稱 | 說明 | |
---|---|---|
![]() |
Dispose | Release the resources held by this instance. |
![]() |
Equals | (繼承自 Object。) |
![]() |
GetHashCode | (繼承自 Object。) |
![]() |
GetType | (繼承自 Object。) |
![]() ![]() |
Load(Stream) | Load a package from the specified Stream. |
![]() ![]() |
Load(String) | Load a package file specified by fileName. |
![]() ![]() |
Load(Stream, DacSchemaModelStorageType) | Loads a package from the specified Stream. |
![]() ![]() |
Load(String, DacSchemaModelStorageType) | Loada a package file specified by fileName. |
![]() ![]() |
Load(Stream, DacSchemaModelStorageType, FileAccess) | Load a package from the specified Stream. |
![]() ![]() |
Load(String, DacSchemaModelStorageType, FileAccess) | Load a package file specified by fileName. |
![]() |
ToString | (繼承自 Object。) |
![]() |
Unpack | Place the contents of this package into the directory specified by directoryPath. |
上層
擴充 方法
名稱 | 說明 | |
---|---|---|
![]() |
GetCollationString | Gets the collation associated with the specified package. (由 DacExtensions 定義。) |
![]() |
UpdateModel | 更新 DacPackage 中的模型,以新的模型取代目前的模型。在更新之前,此模型將會經過驗證,如果遇到錯誤則會擲回 DacServicesException。如果呼叫端想要封鎖警告和錯誤,他們必須藉由呼叫 Validate() 及檢查傳回的訊息中是否包含任何錯誤或警告來驗證此模型。注意:只有模型會被取代 - 所有其他成品 (例如重構記錄、預先部署指令碼、部署後指令碼和參與者成品) 都不會更動。如果這些成品中有任何一個依賴不再位於更新之模型中的元素,則部署可能會失敗。呼叫端必須負責確認這些成品與新的模型一致。Package API 可用來更新其他成品 (例如重構記錄和指令碼),並使其與更新的模型維持一致狀態。這些成品會儲存為封裝組件,並以其 URI 加以識別。封裝組件可以使用 GetParts() 加以檢查。請參閱 Package API,以取得有關更新封裝組件的進一步資訊。 (由 DacPackageExtensions 定義。) |
上層
執行緒安全性
這個型別的任何公用 static (在 Visual Basic 中為 Shared) 成員都是執行緒安全的。並不是所有的執行個體成員都保證可以用於所有的執行緒。