File: Default_Dispatcher_Impl.h

package info (click to toggle)
ace 6.4.5%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 48,640 kB
  • ctags: 41,204
  • sloc: cpp: 336,448; perl: 33,068; ansic: 20,676; sh: 3,735; exp: 787; python: 635; yacc: 511; xml: 330; lex: 158; lisp: 116; makefile: 80; csh: 20; tcl: 5
file content (75 lines) | stat: -rw-r--r-- 1,716 bytes parent folder | download | duplicates (3)
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/* -*- C++ -*- */
/**
 *  @file   Default_Dispatcher_Impl.h
 *
 *  @author Venkita Subramonian (venkita@cs.wustl.edu)
 *
 * Based on previous work by Tim Harrison (harrison@cs.wustl.edu),
 * Chris Gill, Carlos O'Ryan and other members of the DOC group.
 */

#ifndef DEFAULT_DISPATCHER_IMPL_H
#define DEFAULT_DISPATCHER_IMPL_H
#include /**/ "ace/pre.h"

#include "ace/Task.h"


#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */

#include "ace/Auto_Ptr.h"
#include "kokyu_export.h"
#include "Kokyu_defs.h"
#include "Dispatcher_Impl.h"
#include "Dispatcher_Task.h"

namespace Kokyu
{
  /**
   * @class Default_Dispatcher_Impl
   *
   * @brief Default implementation class for EC dispatcher
   * implementations
   *
   */
  class Default_Dispatcher_Impl : public Dispatcher_Impl
  {
  public:
    Default_Dispatcher_Impl ();

  private:
    int activate_i ();
    int init_i (const Dispatcher_Attributes&);
    int dispatch_i (const Dispatch_Command*,
                  const QoSDescriptor&);
    int shutdown_i ();
    Dispatcher_Task* find_task_with_preemption_prio (Priority_t);

  private:
    typedef auto_ptr<Dispatcher_Task> Dispatcher_Task_Auto_Ptr;
    ACE_Auto_Array_Ptr<Dispatcher_Task_Auto_Ptr> tasks_;
    int ntasks_;
    ConfigInfoSet curr_config_info_;
    int activated_;
  };

  class Shutdown_Task_Command : public Dispatch_Command
  {
  public:
    /// Constructor
    Shutdown_Task_Command (ACE_Allocator *mb_allocator = 0);

    /// Command callback
    int execute ();
  };

} //end of namespace

#if defined (__ACE_INLINE__)
#include "Default_Dispatcher_Impl.inl"
#endif /* __ACE_INLINE__ */

#include /**/ "ace/post.h"
#endif /* DEFAULT_DISPATCHER_IMPL_H */