Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Buffer {
- private int buff;
- public Buffer(int buff) {
- super();
- this.buff = buff;
- }
- public synchronized void put(int n)
- {
- buff=n;
- }
- public synchronized int getBuff()
- {
- return buff;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement