Class EditorFileScopeActionResponseBuilder

EditorFileScopeActionResponseBuilder

เครื่องมือสร้างสำหรับออบเจ็กต์ EditorFileScopeActionResponse รายการ

วิธีการ

วิธีการประเภทการแสดงผลรายละเอียดแบบย่อ
build()EditorFileScopeActionResponseสร้างการตอบสนองการดำเนินการของ Editor ปัจจุบัน
requestFileScopeForActiveDocument()EditorFileScopeActionResponseBuilderขอขอบเขต drive.file สำหรับเอกสารเครื่องมือแก้ไขที่ใช้งานอยู่ในปัจจุบัน

เอกสารประกอบโดยละเอียด

build()

สร้างการตอบสนองการดำเนินการของ Editor ปัจจุบัน

รีเทิร์น

EditorFileScopeActionResponseEditorFileScopeActionResponse ที่ผ่านการตรวจสอบความถูกต้อง


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 — ออบเจ็กต์นี้สำหรับการทำเชน