There is a lot of posts how to laod image from firebase but I still don't understand them. My code does nothing so please give me an example method.
I can't understand how to use the Glide or Picasso what to insert into .with .load and .into.
My goal is to load everything from whole category and display it in one fragment. My firebase storage structure (I attached json):
{
"Category1": {
"01": {
"imageLink": "https://firebasestorage.googleapis.com/v0/b/wallex0111.appspot.com/o/photo_2018-10-19_21-38-21.jpg?alt=media&token=f1d29e64-a9ca-4c71-aba7-8144992c835e",
},
"02": {
"imageLink": "https://firebasestorage.googleapis.com/v0/b/wallex0111.appspot.com/o/photo_2018-10-31_10-38-06.jpg?alt=media&token=6889a3b8-3691-41ea-9162-91558ba4181b",
},
"03": {
"imageLink": "https://firebasestorage.googleapis.com/v0/b/wallex0111.appspot.com/o/photo_2018-10-06_14-19-41.jpg?alt=media&token=e75b0096-aaf5-4952-827b-7efb71d6723c",
}
},
"Category2": {
"01": {
"imageLink": "https://firebasestorage.googleapis.com/v0/b/wallex0111.appspot.com/o/photo_2018-10-07_13-55-55.jpg?alt=media&token=bd37d98c-215a-4caf-bf37-d43d78736c31",
},
"02": {
"imageLink": "https://firebasestorage.googleapis.com/v0/b/wallex0111.appspot.com/o/photo_2018-10-31_10-38-06.jpg?alt=media&token=6889a3b8-3691-41ea-9162-91558ba4181b",
}
}
}
Fragment
public class AllFrtagment extends Fragment {}
xml layout
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".Fragments.AllFrtagment">
<RelativeLayout
android:id="@+id/relLayyout1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"></RelativeLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/relLayyout1"
android:orientation="vertical"
android:weightSum="100">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="60">
<GridView
android:id="@+id/gridView"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginTop="1dp"
android:layout_weight="40"
android:gravity="center"
android:horizontalSpacing="1dp"
android:numColumns="5"
android:stretchMode="none"
android:verticalSpacing="1dp"></GridView>
<!--I think that using GridView is all I need...? Without additional ImageView-->
<ImageView
android:id="@+id/galleryImageView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop" />
</RelativeLayout>
</LinearLayout>
</RelativeLayout>