Back to index

salome-kernel  6.5.0
Defines | Functions
SALOMELocalTraceTest.cxx File Reference
#include "SALOMELocalTraceTest.hxx"
#include <iostream>
#include <fstream>
#include <string>
#include <cstdlib>
#include "LocalTraceBufferPool.hxx"
#include "utilities.h"

Go to the source code of this file.

Defines

#define TRACEFILE   "/tmp/traceUnitTest.log"
#define NUM_THREADS   2
#define NUM_MESSAGES   5

Functions

void * PrintHello (void *threadid)
 NUM_THREAD are created with function PrintHello, which produces NUM_MESSAGES traces.

Define Documentation

#define NUM_MESSAGES   5

Definition at line 88 of file SALOMELocalTraceTest.cxx.

#define NUM_THREADS   2

Definition at line 87 of file SALOMELocalTraceTest.cxx.

#define TRACEFILE   "/tmp/traceUnitTest.log"

Definition at line 55 of file SALOMELocalTraceTest.cxx.


Function Documentation

void * PrintHello ( void *  threadid)

NUM_THREAD are created with function PrintHello, which produces NUM_MESSAGES traces.

Definition at line 181 of file SALOMELocalTraceTest.cxx.

{
#if defined(_DEBUG_) || defined(_DEBUG)
  long id_thread = (long)threadid;
  for (int i=0; i<NUM_MESSAGES;i++)
  MESSAGE("Hello World! This is a trace test : " << id_thread 
        << " - iter " << i);
#endif
  pthread_exit(NULL);
}

Here is the caller graph for this function: