mirror of
https://github.com/antebudimir/tempus.git
synced 2026-01-01 18:03:33 +00:00
feat: radio
This commit is contained in:
parent
1deb9ed3d7
commit
a1ee70c24f
16 changed files with 478 additions and 11 deletions
|
|
@ -0,0 +1,26 @@
|
|||
package com.cappielloantonio.play.viewmodel;
|
||||
|
||||
import android.app.Application;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.lifecycle.AndroidViewModel;
|
||||
import androidx.lifecycle.LiveData;
|
||||
|
||||
import com.cappielloantonio.play.repository.RadioRepository;
|
||||
import com.cappielloantonio.play.subsonic.models.InternetRadioStation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class RadioViewModel extends AndroidViewModel {
|
||||
private final RadioRepository radioRepository;
|
||||
|
||||
public RadioViewModel(@NonNull Application application) {
|
||||
super(application);
|
||||
|
||||
radioRepository = new RadioRepository();
|
||||
}
|
||||
|
||||
public LiveData<List<InternetRadioStation>> getInternetRadioStations() {
|
||||
return radioRepository.getInternetRadioStations();
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue