Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

stiltimelist.h

Go to the documentation of this file.
00001 /*******************************************************************************
00002  * Copyright (c) 2006 International Business Machines Corporation
00003  * All rights reserved. This program and the accompanying materials
00004  * are made available under the terms of the Common Public License v1.0
00005  * which accompanies this distribution, and is available at
00006  * http://www.opensource.org/licenses/cpl1.0.php
00007  *
00008  * Contributors:
00009  *    Douglas Sprague, Joel Wheeler - initial API and implementation
00010  *
00011  *****************************************************************************/
00012 
00013 #ifndef STILTimeList_H
00014 #define STILTimeList_H
00015 
00016 
00017 #include "stilcom.h"               // Common library
00018 #include "stiltimeexpr.h"
00019 
00020 #include <vector>
00021 
00022 //---------------------------------------------------------------------------
00028 //---------------------------------------------------------------------------
00029 class STILTimeList  {
00030 
00031   // - Public members
00032   public:
00033   // - Default constructor
00034     STILTimeList();
00035 
00036     // - Copy Constructor
00037     STILTimeList(const STILTimeList &);
00038 
00039     // - Destructor
00040     ~STILTimeList();
00041 
00042     // - Assignment operator
00043     STILTimeList & operator=(const STILTimeList &);
00044 
00045     // - Initialize/reset this object
00046     void  init();
00047 
00048     // - Get the number of events in the list
00049     LONG getCount() const ;
00050 
00051     // - Reference a specific event in the list
00052     const STILTimeExpr& operator[](const LONG&) const;
00053 
00054     // - Add an event to the list
00055     void addTime(const STILTimeExpr&);
00056 
00057   // - Private members
00058   private:
00059 
00060     std::vector<STILTimeExpr> m_timeList;
00061 
00062 };
00063 
00065 //--------------------------------------------------------------------------
00073 //--------------------------------------------------------------------------
00074 inline void STILTimeList::init()           { m_timeList.clear(); }
00075 
00076 //--------------------------------------------------------------------------
00084 //--------------------------------------------------------------------------
00085 inline LONG STILTimeList::getCount() const { return m_timeList.size(); }
00086 
00087 #endif

This page last updated on 6 Jul 2007

SourceForge.net Logo