当我使用gooogle或Facebook注册时,我可以在控制台中看到我的displayName。但是,当我使用电子邮件和密码注册时,在控制台中看不到displayName,它返回null。但是有趣的部分是它在Firebase数据库中设置了显示名称,但无法检索。
// Program to implement 2D transformations on a rectangle.
// (1) Translation (2) Rotation (3) Scaling.
#include<iostream.h>
#include<stdlib.h>
#include<conio.h>
#include<graphics.h>
#include<math.h>
void main()
{
clrscr();
int tx,ty,c,t,i,j,k,sx,sy,x1,x2,y1,y2;
float tx1;
int gd = DETECT, gm;
initgraph(&gd, &gm,"C:\\TC\\BGI");
x1 = y2 = 100;
x2 = y1 = 150;
rectangle(x1,y1,x2,y2);
cout<<"Enter any one transformation:\n1:Translation \n2:Rotation \n3:Scaling ";
cout<<"\nSelected: ";
cin>>c;
switch(c)
{
case 1:
cout<<"Enter tx & ty :";
cin>>tx>>ty;
rectangle(x1+tx, y1+ty, x2+tx, y2+ty);
break;
case 2 :
int xx1, yy1, xx2, yy2, xx3, yy3, xx4, yy4;
int ax1, ay1, ax2, ay2, ax3, ay3, ax4, ay4;
int refx, refy;
cout<<"Enter an angle for rotation: ";
cin>>tx1;
tx1=tx1*(3.14/180);
refx = refy = 100;
xx1 = yy1 = yy2 = xx4 = 100;
xx2 = xx3 = yy3 = yy4 = 150;
ax1 = refy +(xx1-refx)* cos(tx1)-(yy1-refy)*sin(tx1);
ay1 = refy +(xx1-refx)* sin(tx1)+(yy1-refy)*cos(tx1);
ax2 = refy +(xx2-refx)* cos(tx1)-(yy2-refy)*sin(tx1);
ay2 = refy +(xx2-refx)* sin(tx1)+(yy2-refy)*cos(tx1);
ax3 = refy +(xx3-refx)* cos(tx1)-(yy3-refy)*sin(tx1);
ay3 = refy +(xx3-refx)* sin(tx1)+(yy3-refy)*cos(tx1);
ax4 = refy +(xx4-refx)* cos(tx1)-(yy4-refy)*sin(tx1);
ay4 = refy +(xx4-refx)* sin(tx1)+(yy4-refy)*cos(tx1);
line(ax1,ay1, ax2, ay2);
line(ax2,ay2, ax3, ay3);
line(ax3,ay3, ax4, ay4);
line(ax4,ay4, ax1, ay1);
break;
case 3 :
cout<<"Enter sx & sy: ";
cin>>sx>>sy;
rectangle(x1*sx, y1*sy, x2*sx, y2*sy);
break;
default :
cout<<"Error! Enter a valid choice";
}
getch();
closegraph();
}
答案 0 :(得分:0)
Firebase身份验证中的新电子邮件/密码帐户未设置显示名称。如果要在创建帐户后添加一个,则必须update the profile as described in the documentation。