SST  6.0.0
StructuralSimulationToolkit
uninitializedQueue.h
1 // Copyright 2009-2016 Sandia Corporation. Under the terms
2 // of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S.
3 // Government retains certain rights in this software.
4 //
5 // Copyright (c) 2009-2016, Sandia Corporation
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 
13 #ifndef SST_CORE_UNINITIALIZEDQUEUE_H
14 #define SST_CORE_UNINITIALIZEDQUEUE_H
15 
16 #include <sst/core/activityQueue.h>
17 
18 namespace SST {
19 
20 /** Always unitialized queue
21  * @brief Used for debugging, and preventing accidentally sending messages
22  * into an incorrect queue
23  */
25 public:
26  /** Create a new Queue
27  * @param message - Message to print when something attempts to use this Queue
28  */
29  UninitializedQueue(std::string message);
30  UninitializedQueue(); // Only used for serialization
32 
33  bool empty();
34  int size();
35  void insert(Activity* activity);
36  Activity* pop();
37  Activity* front();
38 
39 
40 private:
41  std::string message;
42 
43 };
44 
45 } //namespace SST
46 
47 #endif // SST_CORE_UNINITIALIZEDQUEUE_H
Activity * pop()
Remove and return the next activity.
Definition: uninitializedQueue.cc:47
void insert(Activity *activity)
Insert a new activity into the queue.
Definition: uninitializedQueue.cc:41
Base class for all Activities in the SST Event Queue.
Definition: activity.h:53
Always unitialized queue.
Definition: uninitializedQueue.h:24
bool empty()
Returns true if the queue is empty.
Definition: uninitializedQueue.cc:29
int size()
Returns the number of activities in the queue.
Definition: uninitializedQueue.cc:35
Definition: action.cc:17
Base Class for a queue of Activities.
Definition: activityQueue.h:22
Activity * front()
Returns the next activity.
Definition: uninitializedQueue.cc:53