From b2dbfcc317d7cdec57cc4081801e75a9d25b1d07 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sun, 1 May 2011 19:14:55 +0200 Subject: Fix formatting git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@52 72836036-5685-4462-b002-a69064685172 --- src/jrummikub/util/Event.java | 2 +- src/jrummikub/util/Event1.java | 2 +- src/jrummikub/util/Event2.java | 4 ++-- src/jrummikub/util/IEvent.java | 1 + src/jrummikub/util/IEvent1.java | 1 + src/jrummikub/util/IEvent2.java | 1 + src/jrummikub/util/Pair.java | 29 ++++++++++++++--------------- 7 files changed, 21 insertions(+), 19 deletions(-) (limited to 'src/jrummikub/util') diff --git a/src/jrummikub/util/Event.java b/src/jrummikub/util/Event.java index 0b2317f..1a68eac 100644 --- a/src/jrummikub/util/Event.java +++ b/src/jrummikub/util/Event.java @@ -4,7 +4,7 @@ import java.util.HashSet; public class Event implements IEvent { private HashSet listeners = new HashSet(); - + @Override public void add(IListener listener) { listeners.add(listener); diff --git a/src/jrummikub/util/Event1.java b/src/jrummikub/util/Event1.java index e8ccb43..f0595f9 100644 --- a/src/jrummikub/util/Event1.java +++ b/src/jrummikub/util/Event1.java @@ -4,7 +4,7 @@ import java.util.HashSet; public class Event1 implements IEvent1 { private HashSet> listeners = new HashSet>(); - + @Override public void add(IListener1 listener) { listeners.add(listener); diff --git a/src/jrummikub/util/Event2.java b/src/jrummikub/util/Event2.java index 19d2d58..c7ca8e7 100644 --- a/src/jrummikub/util/Event2.java +++ b/src/jrummikub/util/Event2.java @@ -3,8 +3,8 @@ package jrummikub.util; import java.util.HashSet; public class Event2 implements IEvent2 { -private HashSet> listeners = new HashSet>(); - + private HashSet> listeners = new HashSet>(); + @Override public void add(IListener2 listener) { listeners.add(listener); diff --git a/src/jrummikub/util/IEvent.java b/src/jrummikub/util/IEvent.java index ce0e13d..2295118 100644 --- a/src/jrummikub/util/IEvent.java +++ b/src/jrummikub/util/IEvent.java @@ -2,5 +2,6 @@ package jrummikub.util; public interface IEvent { public void add(IListener listener); + public void remove(IListener listener); } diff --git a/src/jrummikub/util/IEvent1.java b/src/jrummikub/util/IEvent1.java index 47075db..4108078 100644 --- a/src/jrummikub/util/IEvent1.java +++ b/src/jrummikub/util/IEvent1.java @@ -2,5 +2,6 @@ package jrummikub.util; public interface IEvent1 { public void add(IListener1 listener); + public void remove(IListener1 listener); } diff --git a/src/jrummikub/util/IEvent2.java b/src/jrummikub/util/IEvent2.java index f677a2d..ac68c4f 100644 --- a/src/jrummikub/util/IEvent2.java +++ b/src/jrummikub/util/IEvent2.java @@ -2,5 +2,6 @@ package jrummikub.util; public interface IEvent2 { public void add(IListener2 listener); + public void remove(IListener2 listener); } diff --git a/src/jrummikub/util/Pair.java b/src/jrummikub/util/Pair.java index 95af113..5fb8589 100644 --- a/src/jrummikub/util/Pair.java +++ b/src/jrummikub/util/Pair.java @@ -4,21 +4,20 @@ package jrummikub.util; * A pair of objects */ public class Pair { - final T1 first; - final T2 second; - - public Pair(T1 first, T2 second) { - this.first = first; - this.second = second; - } + final T1 first; + final T2 second; - public T1 getFirst() { - return first; - } + public Pair(T1 first, T2 second) { + this.first = first; + this.second = second; + } + + public T1 getFirst() { + return first; + } + + public T2 getSecond() { + return second; + } - public T2 getSecond() { - return second; - } - - } -- cgit v1.2.3