Metode DocsView.setMode
Memilih mode yang akan digunakan tampilan untuk menampilkan dokumen.
Jika menggunakan cakupan selain https://www.googleapis.com/auth/drive
atau
https://www.googleapis.com/auth/drive.readonly
, sebaiknya gunakan
DocsViewMode.LIST
karena pengguna belum memberikan akses ke thumbnail.
Tanda Tangan
setMode(mode: DocsViewMode): DocsView;
Detail
Opsional |
Tidak |
Final |
Tidak |
Dengan kontrasepsi |
Tidak |
Statis |
Tidak |
Parameter
Hasil
DocsView
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2024-11-08 UTC.
[null,null,["Terakhir diperbarui pada 2024-11-08 UTC."],[[["Selects the display mode for documents within the view, using either list or grid view."],["When using restricted scopes, it's advisable to utilize `DocsViewMode.LIST` due to potential limitations on thumbnail access."],["This method is neither optional, final, protected, nor static."],["It accepts a single parameter, 'mode', to specify the desired display mode (list or grid)."],["Upon execution, it returns an updated DocsView object reflecting the mode change."]]],["The `setMode` function determines how documents are displayed, accepting a `DocsViewMode` parameter. Using scopes other than `drive` or `drive.readonly` suggests using `DocsViewMode.LIST` due to limited access. This function is not optional, final, protected, or static. It returns a `DocsView` object, and the selected `mode` dictates the presentation style of documents within the view.\n"]]