My android project has two models - Track and Artist.
Track is used to get the information related to Track and Artist is used to get the details related to Artist.
Here is the sample code for the each model:
Track.class
public class Track {
private int track_ID;
private String title;
private String artist;
private String songWriter;
private String lyrics;
private String album;
private String language;
private int views;
private int year;
private String albumArt;
private String videoURL;
private String shareURL;
public Track(){
//Empty Constructor
}
Artist.class
private int artist_ID;
private String name;
private boolean verified;
private String artistProfilePic;
public Artist(){
//Empty Constructor
}
In the code below I am only able to use Track Model
public class SongAdapter extends FirestoreRecyclerAdapter<Track, SongAdapter.SongHolder> {
My problem is I am not able to use both the model in one FirestoreRecyclerAdapter.
How can I do it?