diff options
Diffstat (limited to 'java/test/Ice/metrics/ThreadObserverI.java')
-rw-r--r-- | java/test/Ice/metrics/ThreadObserverI.java | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/java/test/Ice/metrics/ThreadObserverI.java b/java/test/Ice/metrics/ThreadObserverI.java new file mode 100644 index 00000000000..4221039ae22 --- /dev/null +++ b/java/test/Ice/metrics/ThreadObserverI.java @@ -0,0 +1,29 @@ +// ********************************************************************** +// +// Copyright (c) 2003-2013 ZeroC, Inc. All rights reserved. +// +// This copy of Ice is licensed to you under the terms described in the +// ICE_LICENSE file included in this distribution. +// +// ********************************************************************** + +package test.Ice.metrics; + +class ThreadObserverI extends ObserverI implements Ice.Instrumentation.ThreadObserver +{ + public synchronized void + reset() + { + super.reset(); + states = 0; + } + + public synchronized void + stateChanged(Ice.Instrumentation.ThreadState o, Ice.Instrumentation.ThreadState n) + { + ++states; + } + + int states; +}; + |