Skip to content
Snippets Groups Projects
Stimulus.java 674 B
Newer Older
package com.example.stimulus;

import com.example.notification.Notification;
import com.example.stimulusStrategy.Accelerometer;
import com.example.stimulusStrategy.Clock;
import com.example.stimulusStrategy.StimulusStrategy;

import java.util.Observer;

/**
 * Created by pharmacy on 09/01/2018.
 */

public interface Stimulus extends Observer {

    StimulusStrategy defaultStrategy = new Clock();

    //Creates an instance of the desired notifcation type (Factory Method)
    //TBD if this is to be public
    Notification createNotification();


    //Allows the Stimulus Strategy to be used with this stimlus to be chosen
    void chooseStrategy(StimulusStrategy s);
}