使用Google Drive SDK捕获文件更改 [英] Capturing file changes with Google Drive SDK

查看:102
本文介绍了使用Google Drive SDK捕获文件更改的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

诚实地说,迄今为止我还没有深入研究过Google Drive API,但我不知道API是否支持我所需要的。我希望捕获特定文件夹下的更改,并通知可访问该文件夹的用户。



例如,我有一个名为 Foo ,并且有三个人可以访问该文件夹。当 Person 1 在该文件夹下发生显着变化(上传文件,更改文件,删除文件等)时,我想通知 Person 2 和<强>人3


请注意,这些更改可以在任何地方完成,而不仅仅是来自客户端的
。该用户可以通过Google Drive web
界面进行操作,或者用户可能正在将他/她的计算机与
Google云端硬盘同步。


我头脑中唯一无法想象的部分是如何捕获特定文件夹下的更改。



为了记录,我将使用.NET为我的客户端。

解决方案

您需要的是改变feed在我们刚刚推出的Drive SDK v2中。但是,更改供稿不支持仅检索特定文件夹的更改。相反,它会对用户的整个云端硬盘进行所有更改。这是我们正在考虑实施的一项功能要求,但我没有时间表,我们何时会实施这项功能。


Honest to say, I haven't been able to deeply look inside the Google Drive API so far but I wonder if the API has support for what I need. I would like to capture changes under a specific folder and notify the users which has access to that folder.

For example, I have a folder named Foo and there are three people who have access to that folder. When Person 1 makes a notable change (uploads a file, changes a file, deletes a file, etc) under that folder, I would like to notify the Person 2 and Person 3.

Please note here that these changes can be done from anywhere, not just from my client. The person can take the action through the Google Drive web interface or the user might be syncing his/her computer with the Google Drive.

The only part I cannot visualize in my head is how to capture the changes under a specific folder.

For the record, I will be using .NET for my client.

解决方案

What you're looking for is the changes feed in our just-launched Drive SDK v2. However, the changes feed does not yet support retrieving changes for just a specific folder. Instead, it gives all changes to a user's entire Drive. This is a feature request that we're considering implementing, but I don't have a timeline as to when we'll implement this yet.

这篇关于使用Google Drive SDK捕获文件更改的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆