SST 12.1.0
Structural Simulation Toolkit
activityQueue.h
1// Copyright 2009-2022 NTESS. Under the terms
2// of Contract DE-NA0003525 with NTESS, the U.S.
3// Government retains certain rights in this software.
4//
5// Copyright (c) 2009-2022, NTESS
6// All rights reserved.
7//
8// This file is part of the SST software package. For license
9// information, see the LICENSE file in the top level directory of the
10// distribution.
11
12#ifndef SST_CORE_ACTIVITYQUEUE_H
13#define SST_CORE_ACTIVITYQUEUE_H
14
15#include "sst/core/activity.h"
16
17namespace SST {
18
19/** Base Class for a queue of Activities
20 */
22{
23public:
24 ActivityQueue() {}
25 virtual ~ActivityQueue() {}
26
27 /** Returns true if the queue is empty */
28 virtual bool empty() = 0;
29 /** Returns the number of activities in the queue */
30 virtual int size() = 0;
31 /** Remove and return the next activity */
32 virtual Activity* pop() = 0;
33 /** Insert a new activity into the queue */
34 virtual void insert(Activity* activity) = 0;
35 /** Returns the next activity */
36 virtual Activity* front() = 0;
37
38private:
39};
40
41} // namespace SST
42
43#endif // SST_CORE_ACTIVITYQUEUE_H
Base Class for a queue of Activities.
Definition: activityQueue.h:22
virtual Activity * front()=0
Returns the next activity.
virtual int size()=0
Returns the number of activities in the queue.
virtual bool empty()=0
Returns true if the queue is empty.
virtual void insert(Activity *activity)=0
Insert a new activity into the queue.
virtual Activity * pop()=0
Remove and return the next activity.
Base class for all Activities in the SST Event Queue.
Definition: activity.h:46