package com.example.nuria.fesp_cyl.utils;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;

import com.example.nuria.fesp_cyl.RefreshService;

public class BootReceiver extends BroadcastReceiver {

    private static final String TAG = "BootReceiver";

    @Override
    public void onReceive(Context context, Intent intent) {
        try {
            Thread.sleep(30000);
            context.startService(new Intent(context, RefreshService.class));
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        Log.d(TAG, "onReceive");
    }
}
