Nemiver  0.3
nmv-sequence.h
Go to the documentation of this file.
1 /* -*- Mode: C++; indent-tabs-mode:nil; c-basic-offset:4;-*- */
2 
3 //Authors: Dodji Seketeli
4 //Copyright 2006 Dodji Seketeli
5 /*
6  *This file is part of the nemiver Project.
7  *
8  *Nemiver is free software; you can redistribute
9  *it and/or modify it under the terms of
10  *the GNU General Public License as published by the
11  *Free Software Foundation; either version 2,
12  *or (at your option) any later version.
13  *
14  *Nemiver is distributed in the hope that it will
15  *be useful, but WITHOUT ANY WARRANTY;
16  *without even the implied warranty of
17  *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
18  *See the GNU General Public License for more details.
19  *
20  *You should have received a copy of the
21  *GNU General Public License along with Nemiver;
22  *see the file COPYING.
23  *If not, write to the Free Software Foundation,
24  *Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25  *
26  *See COPYRIGHT file copyright information.
27  */
28 #ifndef __NMV_SEQUENCE_H__
29 #define __NMV_SEQUENCE_H__
30 
31 #include "nmv-api-macros.h"
32 #include "nmv-object.h"
33 #include "nmv-exception.h"
34 
35 namespace nemiver {
36 namespace common {
37 
38 class NEMIVER_API Sequence : public Object {
39  struct Priv;
40  friend struct Priv;
41  SafePtr<Priv> m_priv;
42 
43  //non copyable
44  Sequence (const Sequence &);
45  Sequence& operator= (const Sequence &);
46 
47 public:
48 
52 
53  public:
54  OverflowException (const UString &a_message) :
55  Exception (a_message)
56  {}
57  virtual ~OverflowException () throw () {};
58  };//end class OverflowException
59 
60  Sequence ();
61  virtual ~Sequence ();
62  long long create_next_integer ();//throws OverflowException
63  long long get_current_integer () const;
64 };//end class Sequence
65 
66 }//end namespace common
67 }//end namespace nemiver
68 #endif // __NMV_SEQUENCE_H__
69 
nemiver::common::Object
Definition: nmv-object.h:43
nemiver
Definition: nmv-address.h:31
NEMIVER_EXCEPTION_API
#define NEMIVER_EXCEPTION_API
Definition: nmv-api-macros.h:51
NEMIVER_API
#define NEMIVER_API
Definition: nmv-api-macros.h:53
nmv-api-macros.h
nemiver::common::Sequence::OverflowException
Definition: nmv-sequence.h:49
nemiver::common::UString
Definition: nmv-ustring.h:45
nemiver::common::Sequence
Definition: nmv-sequence.h:38
nemiver::common::Exception
Definition: nmv-exception.h:41
nemiver::common::Sequence::OverflowException::~OverflowException
virtual ~OverflowException()
Definition: nmv-sequence.h:57
nmv-object.h
nemiver::common::Sequence::OverflowException::OverflowException
OverflowException(const UString &a_message)
Definition: nmv-sequence.h:54
nemiver::common::SafePtr< Priv >
nmv-exception.h
common
Definition: nmv-proc-list-dialog.h:32