使用 iOS Evernote API 在 EDAMNote 中嵌入不可见元数据
我正在将 Evernote 与 iOS 应用程序集成,我的客户希望该应用程序能够将用户生成的一些信息与 Evernote 同步。此用例将有一个笔记本,并且将为要存储在云上的应用程序的每个元素创建一个注释,为了成功同步,每个注释必须存储一些只能由应用程序解释且不可见的元数据通过网络界面或桌面/移动客户端。
我提出了 2 种可能的解决方案,但它们并没有让我完全满意:
解决方案 1:
创建标签来存储与一个相关的元数据 注意,对于每个元数据字段,都会有一个新标签,例如“myapp_title”或“myapp_info1”。
优点:该应用程序可以从笔记本下载所有笔记并提取标签中存储的信息。
缺点:用户的帐户将充满仅对应用程序有意义的标签,如果删除应用程序元素,则应删除标签...
解决方案 2:
在注释末尾添加以下部分:仅由应用程序解释,某种仅应由应用程序读取的预格式化文本。
优点:无需弄乱标签
缺点:用户可能会错误地(或故意)删除此信息。 用户可见...
你们知道这个问题的解决方案吗? API 是否允许这种“隐藏”元数据?
每个帮助或线索都会有很大帮助..
谢谢
I am integrating Evernote with an iOS App, my customer wants the app to able to sync some Infos being generated by the user with Evernote. There will be one Notebook for this use case and one Note will be created for each Element of the app to be stored on the cloud, to succeed with sync each note has to store some metadata that should be only interpreted by the app and not visible through the web interface or desktop/mobile clients.
I have came up to 2 possible solutions but they do not make me completely happy:
SOLUTION 1:
Create Tags to store the metadata related to one Note, for each metadata-field there will be a new Tag like "myapp_title" or "myapp_info1".
PROs: The app can download all the notes from the notebook and extract the infos stored in the Tags.
CONs: The user's account will be full of Tags that make only sense for the app, tags should be deleted if App Elements are deleted...
SOLUTION 2:
Include at the end of the Note a part to be only interpreted by the app, some kind of pre-formatted text that should only be read by the app.
PROs: No need to messup Tags
CONS: User can delete this information by mistake (or on purpose).
Visible by the user...
Do you guys know a solution for this? Does the API allow this kind of "hidden" metadata?
Every help or clue would help a lot..
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
使用新的 Note.attributes.applicationData 字段: http://discussion.evernote.com/主题/22731-api-更新/
Use the new Note.attributes.applicationData field: http://discussion.evernote.com/topic/22731-api-updated/
正如在开发者论坛上的回答< /a>,作者:SethH。
您可以将元数据添加到 Note.attributes.sourceApplication字段,我们的应用程序不会使用或向用户公开该字段。请以
consumerkey:{metadata}
的形式插入您的元数据,并很好地处理其他应用可能在此字段中存储的数据。是否有任何首选分隔符可用于与其他应用程序留下的元数据分开,或者是否由每个开发人员决定?
让我们使用分号:
As answered on the developer forum, by SethH.
You can add metadata to the Note.attributes.sourceApplication field, which our apps don't use or expose to the user. Please insert your metadata in the form
consumerkey:{metadata}
and play nicely with data that other apps might stash in this field.Is there any favored delimiter to use to separate from metadata other apps have left, or is it just left up to each developer?
Let's go with semicolon: