diff --git a/app/src/main/java/org/ntlab/amaryllis/client/Amaryllis.java b/app/src/main/java/org/ntlab/amaryllis/client/Amaryllis.java index 92081c7..bebc9ad 100644 --- a/app/src/main/java/org/ntlab/amaryllis/client/Amaryllis.java +++ b/app/src/main/java/org/ntlab/amaryllis/client/Amaryllis.java @@ -1,9 +1,16 @@ package org.ntlab.amaryllis.client; import android.app.Application; +import android.content.Intent; import android.content.SharedPreferences; import android.location.Location; +import org.ntlab.amaryllis.client.entities.AmaryllisBackgroundService; +import org.ntlab.amaryllis.client.entities.PlayListListener; +import org.ntlab.amaryllis.client.voiceservice.VoiceMemo; + +import java.util.ArrayList; + public class Amaryllis extends Application { private String token = null; private String uid = null; @@ -11,7 +18,18 @@ private String name = null; private String new_introduction = null; private Location location; - + private ArrayList playListListeners; + private int index=0; + AmaryllisBackgroundService amaryllisbackgroundservice; + private ArrayList playList; + +// public Amaryllis(){ +// super(); +// Intent intent=new Intent(this,amaryllisbackgroundservice.getClass()); +// startService(intent); +// amaryllisbackgroundservice=(AmaryllisBackgroundService)getApplicationContext(); +// for(PlayListListener pl: playListListeners) amaryllisbackgroundservice.subscribe(pl); +// } public void setUid(String uid) { SharedPreferences prefData = getSharedPreferences("pref_data", MODE_PRIVATE); SharedPreferences.Editor editor = prefData.edit(); @@ -95,8 +113,12 @@ return location; } - public void getBackgroundService(){ + public AmaryllisBackgroundService getBackgroundService() { + return amaryllisbackgroundservice; + } + + public void getPlayList(){ } }