Class EditorFileScopeActionResponseBuilder

ویرایشگرفایل‌اسکوپ‌اکشن‌پاسخ‌ساز

یک سازنده برای اشیاء EditorFileScopeActionResponse .

روش‌ها

روش نوع بازگشتی شرح مختصر
build() Editor File Scope Action Response پاسخ اقدام فعلی ویرایشگر را می‌سازد.
request File Scope For Active Document() Editor File Scope Action Response Builder دامنه‌ی 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.
CardService.newEditorFileScopeActionResponseBuilder()
    .requestFileScopeForActiveDocument()
    .build();

نکته: برای فراخوانی این متد، باید دامنه‌ی drive.file را به فایل manifest افزونه اضافه کنید.

بازگشت

EditorFileScopeActionResponseBuilder — این شیء، برای زنجیره‌سازی.