diff -r 89d6a7a84779 -r 25a17d01db0c Symbian3/Examples/guid-6013a680-57f9-415b-8851-c4fa63356636/class_c_smp_example.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/Examples/guid-6013a680-57f9-415b-8851-c4fa63356636/class_c_smp_example.html Fri Jan 22 18:26:19 2010 +0000 @@ -0,0 +1,325 @@ + +
+Public Member Functions | |
virtual | ~CSmpExample () |
void | CreateDatabaseL (const TDesC &aDbName) |
void | PrintMessage () |
void | StartThreads () |
Static Public Member Functions | |
static CSmpExample * | NewL () |
static TInt | ReadThreadFuncL (TAny *aPtr) |
static TInt | WriteThread1FuncL (TAny *aPtr) |
static TInt | WriteThread2FuncL (TAny *aPtr) |
static void | ReadBothDatabasesL () |
static void | ReadDatabaseL (const TDesC &aDbName, CConsoleBase &console) |
static void | WriteDbFuncL (const TDesC &aDbName, TInt aNum) |
Protected Member Functions | |
void | ConstructL () |
Definition at line 28 of file SmpExample.h.
+CSmpExample::~CSmpExample | +( | ++ | ) | + [virtual] |
+
+Destructor +
Definition at line 22 of file SmpExample.cpp.
+ ++
CSmpExample * CSmpExample::NewL | +( | ++ | ) | + [static] |
+
+NewL() +
Definition at line 33 of file SmpExample.cpp.
+ +void CSmpExample::CreateDatabaseL | +( | +const TDesC & | +aDbName | +) | ++ |
+Creates a named database with the name specified in the parameter, creates a table and adds columns to it. +
Definition at line 351 of file SmpExample.cpp.
+ +TInt CSmpExample::ReadThreadFuncL | +( | +TAny * | +aPtr | +) | + [static] |
+
+This function is called when iReadThread is resumed. It creates a cleanup stack and calls ReadBothDatabasesL() to read both the databases. +
Definition at line 220 of file SmpExample.cpp.
+ +TInt CSmpExample::WriteThread1FuncL | +( | +TAny * | +aPtr | +) | + [static] |
+
+This function is called when iWriteThread is resumed. It creates a cleanup stack and calls WriteDbFuncL() to write integers to KDatabase1. +
Definition at line 324 of file SmpExample.cpp.
+ +TInt CSmpExample::WriteThread2FuncL | +( | +TAny * | +aPtr | +) | + [static] |
+
+This function is called when iWriteThread is resumed. It creates a cleanup stack and calls WriteDbFuncL() to write integers to KDatabase2. +
Definition at line 297 of file SmpExample.cpp.
+ +void CSmpExample::ReadBothDatabasesL | +( | ++ | ) | + [static] |
+
+Creates a console, reads the databases and prints output to the console. +
Definition at line 199 of file SmpExample.cpp.
+ +void CSmpExample::ReadDatabaseL | +( | +const TDesC & | +aDbName, | +|
+ | + | CConsoleBase & | +console | + |
+ | ) | + [static] |
+
+Opens the database named in the first parameter, reads it and prints the output to the console. +
Definition at line 131 of file SmpExample.cpp.
+ +void CSmpExample::WriteDbFuncL | +( | +const TDesC & | +aDbName, | +|
+ | + | TInt | +aNum | + |
+ | ) | + [static] |
+
+Opens the database specified in the first parameter aDbName and writes consecutive integers to it starting from the number specified in the second parameter aNum. +
Definition at line 245 of file SmpExample.cpp.
+ +void CSmpExample::PrintMessage | +( | ++ | ) | ++ |
+Prints welcome message and purpose of the example. +
Definition at line 106 of file SmpExample.cpp.
+ +void CSmpExample::StartThreads | +( | ++ | ) | ++ |
+Starts the three threads +
Definition at line 75 of file SmpExample.cpp.
+ +void CSmpExample::ConstructL | +( | ++ | ) | + [protected] |
+
+Creates three threads; one for reading from the databases and the other two for writing to the databases. +
Definition at line 45 of file SmpExample.cpp.
+ ++