Class EditorFileScopeActionResponseBuilder

編輯器檔案範圍動作回應建構工具

EditorFileScopeActionResponse 物件的建構工具。

方法

方法傳回類型簡短說明
build()EditorFileScopeActionResponse建構目前的編輯器動作回應。
requestFileScopeForActiveDocument()EditorFileScopeActionResponseBuilder要求目前使用中編輯器文件的 drive.file 範圍。

內容詳盡的說明文件

build()

建構目前的編輯器動作回應。

回攻員

EditorFileScopeActionResponse — 經過驗證的EditorFileScopeActionResponse


requestFileScopeForActiveDocument()

要求目前使用中編輯器文件的 drive.file 範圍。

// Display a permissions dialog to the user, requesting `drive.file` scope for
// the current document on behalf of this add-on.
AddOnsResponseService.newEditorFileScopeActionResponseBuilder()
    .requestFileScopeForActiveDocument()
    .build();

注意:如要呼叫這個方法,您必須將 drive.file 範圍新增至外掛程式的資訊清單。

回攻員

EditorFileScopeActionResponseBuilder - 這個物件,用於鏈結。