前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >谷歌文档数据结构

谷歌文档数据结构

作者头像
拿我格子衫来
发布2022-01-24 11:05:37
2930
发布2022-01-24 11:05:37
举报
文章被收录于专栏:TopFE

查看了谷歌文档的介绍,发现谷歌的文档数据竟然是json对象。

一个document对象下第一层是以下几个属性

代码语言:javascript
复制
document: {
    body: ... ,
    documentStyle: ... ,
    lists: ... ,
    documentId: ... ,
    namedStyles: ... ,
    revisionId: ... ,
    title: ...
}

意思就是说,我们所看到的谷歌文档 都是以json数据存储的。 真是不可思议

示意图

正文内容基本上是只是一个序列 StructuralElement 对象。每个StructuralElement对象通过其内容元素的个性化,如图所示,下图中:

结构元素和它们的内容对象包含文档的所有文字,内嵌图像,等等

类型 页眉页脚,和 脚注 具有同样包含结构元件的序列内容元素。

段落包含一个名为元素的一种特殊类型的 ParagraphElement中 的作品就像一个StructuralElement:它是由它自己的一套的内容类型的个性化,如图所示,如下图:

正文内容中的大多数元素具有startIndexendIndex性质。这些指示偏移的元件的开始和结束,相对于其包围段的开始的。

许多元素是可以修改的使用BatchUpdate方法。例如,使用 InsertTextRequest 请求类型,则可以修改包含任何文本元素的内容; 同样,你可以使用 UpdateTextStyleRequest 格式设置应用到包含在一个或多个元素的文本范围。

Scope

Meaning

Usage

https://www.googleapis.com/auth/drive.appfolder

Allows access to the Application Data folder.

Recommended

https://www.googleapis.com/auth/drive.file

Per-file access to files created or opened by the app. File authorization is granted on a per-user basis and is revoked when the user deauthorizes the app.

Recommended

https://www.googleapis.com/auth/drive.install

Special scope used to let users approve installation of an app, and scope needs to be requested.

Recommended

https://www.googleapis.com/auth/drive.apps.readonly

Allows read-only access to installed apps.

Sensitive

https://www.googleapis.com/auth/drive.metadata

Allows read-write access to file metadata (excluding downloadUrl and contentHints.thumbnail), but does not allow any access to read, download, write or upload file content. Does not support file creation, trashing or deletion. Also does not allow changing folders or sharing in order to prevent access escalation.

Restricted

https://www.googleapis.com/auth/drive

Full, permissive scope to access all of a user's files, excluding the Application Data folder.

Restricted

https://www.googleapis.com/auth/drive.activity

Allows read and write access to the Drive Activity API.

Restricted

https://www.googleapis.com/auth/drive.activity.readonly

Allows read-only access to the Drive Activity API.

Restricted

https://www.googleapis.com/auth/drive.readonly

Allows read-only access to file metadata and file content.

Restricted

https://www.googleapis.com/auth/drive.metadata.readonly

Allows read-only access to file metadata (excluding downloadUrl and contentHints.thumbnail), but does not allow any access to read or download file content.

Restricted

https://www.googleapis.com/auth/drive.scripts

Allows access to Apps Script files.

Restricted

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
相关产品与服务
数据保险箱
数据保险箱(Cloud Data Coffer Service,CDCS)为您提供更高安全系数的企业核心数据存储服务。您可以通过自定义过期天数的方法删除数据,避免误删带来的损害,还可以将数据跨地域存储,防止一些不可抗因素导致的数据丢失。数据保险箱支持通过控制台、API 等多样化方式快速简单接入,实现海量数据的存储管理。您可以使用数据保险箱对文件数据进行上传、下载,最终实现数据的安全存储和提取。
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档