binibiningtinamoran

AbstractSubject

Nov 8th, 2019
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.29 KB | None | 0 0
  1. public abstract class AbstractSubject {
  2.  
  3.     private int state;
  4.  
  5.     public void setState(int state) {
  6.         this.state = state;
  7.     }
  8.  
  9.     public int getState() {
  10.         return state;
  11.     }
  12.  
  13.     public abstract void notifySpies();
  14.     public abstract void addSpy(AbstractSpy spy);
  15. }
Add Comment
Please, Sign In to add comment