*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* Type of event sent from test code. Usually String will be
* sufficient. The event type must provide a sensible implementation
* of {@link java.lang.Object#equals(java.lang.Object)}.
* Type of event sent from test code. Usually String will be
* sufficient. The event type must provide a sensible implementation
* of {@link java.lang.Object#equals(java.lang.Object)}.
if (eventList == null) {
eventList = new ArrayList<Event>();
events.put(current, eventList);
}
if (eventList == null) {
eventList = new ArrayList<Event>();
events.put(current, eventList);
}
*/
public synchronized boolean isEventSent(Thread aThread, Event aEvent) {
List<Event> eventList = events.get(aThread);
*/
public synchronized boolean isEventSent(Thread aThread, Event aEvent) {
List<Event> eventList = events.get(aThread);
*/
public synchronized List<Event> getEvents(Thread aThread) {
List<Event> eventList = events.get(aThread);
*/
public synchronized List<Event> getEvents(Thread aThread) {
List<Event> eventList = events.get(aThread);
- public synchronized int getEventCount() {
- int count = 0;
- for (Thread thread: events.keySet()) {
- count += events.get(thread).size();
- }
- return count;
+ public synchronized int getEventCount() {
+ int count = 0;
+
+ for (Thread thread : events.keySet()) {
+ count += events.get(thread).size();
+ }
+
+ return count;