为什么Parse.com上的默认用户数据库名为“_User”? [英] Why is the default User Database on Parse.com called "_User"?

查看:142
本文介绍了为什么Parse.com上的默认用户数据库名为“_User”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这可能是一个坏问题,但我只是好奇为什么Parse会将其默认用户表命名为_User。我花了大约3个小时,当我第一次与解析工作,以解决为什么没有什么将从我的查询返回到该表。

This might be a bad question, but I'm just curious as to why Parse would name their default User table as _User. I spent about 3 hours when I first worked with parse trying to figure out why nothing would return from my queries to that table.

只有当我在Chrome浏览器

Only after I hovered over the table in Chrome did I see in the bottom left of my window the proper name, "_User," at the end of the URL.

推荐答案

我在窗口的左下角看到了正确的名字_User它是一个特殊的类,具有特殊的处理,不要与开发人员创建的类具有相同的行为混淆。 _Installation也是一样。是的,它造成了一些混乱,这是不幸的。通常我们的文档仔细地指定它像这样而不是使用一个字符串名称:

It's a special class with special handling, not to be confused with classes created by the developer which all have the same behavior. The same goes for _Installation too. Yes, it has caused some confusion, which is unfortunate. Usually our documentation carefully specifies it like this rather than using a string name:

JavaScript:

JavaScript:

var query = new Parse.Query(Parse.User);

Android:

ParseQuery<ParseUser> query = ParseUser.getQuery();

iOS:

PFQuery *query = [PFUser query];

这篇关于为什么Parse.com上的默认用户数据库名为“_User”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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