当我在循环中打印子项时,我正在使用.ChildAdded
从Firebase中检索一些项目我看到了所有的键和值,它们都是以快速问题开始的,当我走向头部时{{1}我收到系统错误。我该如何解决这个问题
来自循环的Firebase子结果打印*我想仅检索'年龄'*
print(child.value["myKeyhere"])
我的代码
Snap (age) 54
Snap (email) User1@gmail.com
Snap (firstname) User2Firstname
Snap (lastname) User2Lastname
Snap (profilePic) users/profilePhoto/fKNTGRGfmgdZwtHUyJxOjnKXZzx2.jpg
Snap (receivePostRequest) {
lat = "37.32550194";
long = "-122.01974475";
status = 1;
tags = {
beauty = 0;
heathcare = 0;
house = 1;
housekeeper = 0;
scholar = 0;
student = 0;
};
}
答案 0 :(得分:0)
child.value [ “myKeyhere”]作为!串