package com.example.bot.spring;

import javax.annotation.PostConstruct;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
=======
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

>>>>>>> be34857748acf9bf28ab523e48002190ebdd375e
import com.example.bot.spring.textsender.*;

@Component
public class LineListener extends Thread{
	
	@Autowired
	private ConfirmBroadcaster confirmBroadcaster;
	@Autowired
	private CancelBroadcaster cancelBroadcaster;
	@Autowired
	private UQAnswerReplier uqAnswerReplier;
	@Autowired
	private DoubleElevBroadcaster double11Broadcaster;
	
	public LineListener() {
		//confirmBroadcaster = new ConfirmBroadcaster();
		//cancelBroadcaster = new CancelBroadcaster();
		//uqAnswerReplier = new UQAnswerReplier();
		//double11Broadcaster = new DoubleElevBroadcaster();
	}
	
	@Override
	@PostConstruct
	public void run() {
		while(true) {
			//TODO: Add what ever function need to run
			//execute 1 time per hour
			try { 
				confirmBroadcaster.broadcast();
				cancelBroadcaster.broadcast();
				uqAnswerReplier.broadcast();
				double11Broadcaster.broadcast();				
			}catch(Exception e) {
				e.printStackTrace();
			}
			try {
				Thread.sleep(60000);
			}catch (InterruptedException e) {
				System.err.println("<><><><>Sleep Error<><><><>");
			}
		}
	}
}

@@ -133,64 +133,8 @@
 ed;%0A
-import org.springframework.stereotype.Component;%0A=======
 %0Aimp
@@ -247,57 +247,8 @@
 t;%0A%0A
-%3E%3E%3E%3E%3E%3E%3E be34857748acf9bf28ab523e48002190ebdd375e%0A
 impo

Update LineListener.java