Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(937)

Side by Side Diff: source/test/threadtest/threadtest.h

Issue 1621843002: ICU 56 update step 1 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@561
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/test/threadtest/stringtest.cpp ('k') | source/test/threadtest/threadtest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 //
2 //********************************************************************
3 // Copyright (C) 2002-2011, International Business Machines
4 // Corporation and others. All Rights Reserved.
5 //********************************************************************
6 //
7 // File threadtest.h
8 //
9 #ifndef ABSTRACTTHREADTEST_H
10 #define ABSTRACTTHREADTEST_H
11 //------------------------------------------------------------------------------
12 //
13 // class AbstractThreadTest Base class for threading tests.
14 // Use of this abstract base isolates the part of the
15 // program that nows how to spin up and control threads
16 // from the specific stuff being tested, and (hopefully)
17 // simplifies adding new threading tests for different p arts
18 // of ICU.
19 //
20 // Derived classes: A running test will have exactly one instance of a
21 // derived class, which will persist for the duration of the
22 // test and be shared among all of the threads involved in
23 // the test.
24 //
25 // The constructor will be called in a single-threaded e nvironment,
26 // and should set up any data that will need to persist for the
27 // duration.
28 //
29 // runOnce() will be called repeatedly by the working th reads of
30 // the test in the full multi-threaded environment.
31 //
32 // check() will be called periodically in a single threa ded
33 // environment, with the worker threads temporarily susp ended between
34 // between calls to runOnce(). Do consistency checks he re.
35 //
36 //------------------------------------------------------------------------------
37 class AbstractThreadTest {
38 public:
39 AbstractThreadTest() {};
40 virtual ~AbstractThreadTest();
41 virtual void check() = 0;
42 virtual void runOnce() = 0;
43 };
44
45 #endif // ABSTRACTTHREADTEST_H
OLDNEW
« no previous file with comments | « source/test/threadtest/stringtest.cpp ('k') | source/test/threadtest/threadtest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698