Can someone show me example how to bind service to activity. For example, service is working in background and depending on how it worked it sends messages to activity and activity listens this messages. I can handle only simple service
public class TimeService extends Service {
//
@Override
public void onCreate() {
super.onCreate();
}
@Override
public int onStartCommand(Intent intent, int flags, int start_id) {
return START_NOT_STICKY;
}
@Override
public IBinder onBind(Intent intent) {
return null;
}
}