summaryrefslogtreecommitdiff
path: root/tests/RTScheduling/Current/Thread_Task.h
blob: a6ae16092a1a587dc4b4cb1b2b2d61730bdca8a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
//$Id$
#ifndef THREAD_TASK_H
#define THREAD_TASK_H

#include "tao/RTScheduling/RTScheduler.h"
#include "tao/ORB.h"
#include "ace/Task.h"


class Thread_Task : public ACE_Task <ACE_SYNCH>
{
 public:
  Thread_Task (CORBA::ORB_ptr orb);

  int activate_task (int thr_count);

  ~Thread_Task (void);
  
 protected:
  /// task svc
  virtual int svc (void);
 private:
  CORBA::ORB_var orb_;
 RTScheduling::Current_var current_;
 int active_thread_count_;
 TAO_SYNCH_MUTEX* shutdown_lock_;
 TAO_SYNCH_MUTEX* lock_;
};

#endif /* THREAD_TASK_H */