共用方式為


DataAsyncCommand.DeriveParametersAsync 方法

衍生自類別,以非同步方式,將參數設定為含有指定之命令的使用。

命名空間:  Microsoft.VisualStudio.Data.Framework
組件:  Microsoft.VisualStudio.Data.Framework (在 Microsoft.VisualStudio.Data.Framework.dll 中)

語法

'宣告
Public Sub DeriveParametersAsync ( _
    command As String, _
    commandType As DataCommandType, _
    commandTimeout As Integer, _
    userState As Object _
)
public void DeriveParametersAsync(
    string command,
    DataCommandType commandType,
    int commandTimeout,
    Object userState
)
public:
virtual void DeriveParametersAsync(
    String^ command, 
    DataCommandType commandType, 
    int commandTimeout, 
    Object^ userState
) sealed
abstract DeriveParametersAsync : 
        command:string * 
        commandType:DataCommandType * 
        commandTimeout:int * 
        userState:Object -> unit  
override DeriveParametersAsync : 
        command:string * 
        commandType:DataCommandType * 
        commandTimeout:int * 
        userState:Object -> unit
public final function DeriveParametersAsync(
    command : String, 
    commandType : DataCommandType, 
    commandTimeout : int, 
    userState : Object
)

參數

  • command
    類型:String

    參數是衍生自類別的命令。

  • commandTimeout
    類型:Int32

    時間,以秒為單位),在目前的命令逾時。

  • userState
    類型:Object

    非同步處理序的唯一識別項。

實作

IVsDataAsyncCommand.DeriveParametersAsync(String, DataCommandType, Int32, Object)

例外狀況

例外狀況 條件
ArgumentNullException

command 或 userState 參數為 nullnull 參考 (即 Visual Basic 中的 Nothing)。

ArgumentOutOfRangeException

commandTimeout 參數小於 -1。

備註

這個方法執行的作業與 DeriveParameters 方法相同,不過,以非同步方式。

如果 commandTimeout 參數的值為 0,而不是暫止 (或來說,逾時是無限);如果的值為-1,逾時期間為所設定的資料提供者。

userState 參數唯一識別這個特定非同步作業並傳遞做為 DeriveParametersCompleted 事件的事件引數的一部分,以接聽程式可以判斷非同步處理序完成。

注意事項注意事項

發生的其他例外狀況表示參數衍生這個提供者所指定的原因而失敗。

.NET Framework 安全性

請參閱

參考

DataAsyncCommand 類別

Microsoft.VisualStudio.Data.Framework 命名空間