DarkRay CH
@llsrrll964720
Reviews Written
9
Average Rating
5.0
Posts
Q&A
getDownloadUrl
์คํ ์ด์ putFile ํ ๋ .continueWithTask ์จ์ ์ ์ฅ์์น url ์ป์ด์ค๋ฉด ๋ผ์ //์ด๋ฏธ์ง ์คํ ์ด์db์ ๋ฃ๊ธฐprivate void inputImgToFirebaseDatabase(Uri imageUri){ mStorage.getReference().child("userImages").child(mAuth.getCurrentUser().getUid()).putFile(imageUri).continueWithTask(new Continuation>() { @Override public Task then(@NonNull Task task) throws Exception { if (!task.isSuccessful()) { throw task.getException(); } // Continue with the task to get the download URL return mStorage.getReference().child("userImages").child(mAuth.getCurrentUser().getUid()).getDownloadUrl(); } }).addOnCompleteListener(new OnCompleteListener() { @Override public void onComplete(@NonNull Task task) { String strImageUrl = task.getResult().toString(); User user = new User(); user.name = editTextUserName.getText().toString(); user.profileImgUrl = strImageUrl; mDatabase.getReference().child("users").child(mAuth.getCurrentUser().getUid()).setValue(user); Toast.makeText(UserActivity.this, "๋ณ๊ฒฝ ์๋ฃ!", Toast.LENGTH_SHORT).show(); finish(); startActivity(getIntent()); } });}
- 0
- 8
- 752
Q&A
ํ์ด์ด๋ฒ ์ด์ค ์ํฌํธ ํ ๋ ์ ๋ ์๋์ผ๋ก ์ํฌํธ๊ฐ ๋์ง ์์ต๋๋ค.
console์์ ๋ณ๊ฒฝ์ฌํญ ๊ฒ์ํ๊ณ android ์์ key๋ก getter ์ฐ๋ฉด Remote Config์ ๊ธฐ๋ณธ๊ฐ์ด ๋ถ๋ฌ์์ ธ์
- 0
- 1
- 255




