summaryrefslogtreecommitdiffstats
path: root/simple/simple-http/src/test/java/org/simpleframework/http/core/MockController.java
blob: b6318036f73ffbcaf3464208b209542ab3fd1412 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
package org.simpleframework.http.core;

import java.io.IOException;

import org.simpleframework.transport.Channel;

public class MockController implements Controller {
   
   private boolean ready;
   private boolean sleep;
   private boolean start;
   private boolean initiated;
   private boolean stop;
   
   public void start(Channel channel) throws IOException {
      initiated = true;
   }

   public void ready(Collector collector) throws IOException {
      ready = true;
   }

   public void select(Collector collector) throws IOException {
      sleep = true;
   }  

   public void start(Collector collector) throws IOException {
      start = true;
   }
   
   public void stop() throws IOException {
      stop = true;
   }
   
   public boolean isStopped() {
      return stop;
   }
   
   public boolean isInitiated() {
      return initiated;
   }
   
   public boolean isReady() {
      return ready;
   }
   
   public boolean isSleep() {
      return sleep;
   }
   
   public boolean isStart() {
      return start;
   }
      
}