Class EditorFileScopeActionResponseBuilder

EditorFileScopeActionResponseBuilder

Trình tạo cho các đối tượng EditorFileScopeActionResponse.

Phương thức

Phương thứcKiểu dữ liệu trả vềMô tả ngắn
build()EditorFileScopeActionResponseTạo phản hồi thao tác hiện tại của Trình chỉnh sửa.
requestFileScopeForActiveDocument()EditorFileScopeActionResponseBuilderYêu cầu phạm vi drive.file cho tài liệu Trình chỉnh sửa hiện đang hoạt động.

Tài liệu chi tiết

build()

Tạo phản hồi thao tác hiện tại của Trình chỉnh sửa.

Cầu thủ trả bóng

EditorFileScopeActionResponseEditorFileScopeActionResponse đã xác thực.


requestFileScopeForActiveDocument()

Yêu cầu phạm vi drive.file cho tài liệu Trình chỉnh sửa hiện đang hoạt động.

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

Lưu ý: Để gọi phương thức này, bạn phải thêm phạm vi drive.file vào tệp kê khai của tiện ích bổ sung.

Cầu thủ trả bóng

EditorFileScopeActionResponseBuilder – Đối tượng này để tạo chuỗi.