Use =default for skeleton copy constructor
[ACE_TAO.git] / ACE / ASNMP / asnmp / counter.h
blobae0920596752e7adcde976cf35fb5250b022a03d
1 /* -*-C++-*- */
2 #ifndef COUNTER_
3 #define COUNTER_
4 //=============================================================================
5 /**
6 * @file counter.h
8 * Class definition for SMI Counter32 class.
10 * @author Peter E Mellquist
12 //=============================================================================
14 /*===================================================================
15 Copyright (c) 1996
16 Hewlett-Packard Company
18 ATTENTION: USE OF THIS SOFTWARE IS SUBJECT TO THE FOLLOWING TERMS.
19 Permission to use, copy, modify, distribute and/or sell this software
20 and/or its documentation is hereby granted without fee. User agrees
21 to display the above copyright notice and this license notice in all
22 copies of the software and any documentation of the software. User
23 agrees to assume all liability for the use of the software; Hewlett-Packard
24 makes no representations about the suitability of this software for any
25 purpose. It is provided "AS-IS without warranty of any kind,either express
26 or implied. User hereby grants a royalty-free license to any and all
27 derivatives based upon this software code base.
28 =====================================================================*/
30 #include "asnmp/smival.h"
31 #include "asnmp/integer.h"
33 //------------[ Counter32 Class ]------------------------------------------
34 // The counter class allows all the functionality of unsigned
35 // 32 bit integers but is recognized as a distinct SMI type. Counter32
36 // class objects may be set or get into Vb objects.
38 // This class does not behave as defined by the abstract model
39 // in RFC 1155 section 3.2.3.3
41 /**
42 * @class Counter32
44 * @brief Defines the member functions for the Counter32 concrete class
45 * This class implements RFC 1155 Counter Object and is named
46 * Counter32 after the RFC1902 redefinition of V1 SMI datatypes
48 class ASNMP_Export Counter32 : public SnmpUInt32
50 public:
51 /// constructor with a value
52 Counter32( const unsigned long i = 0);
54 /// copy constructor
55 Counter32( const Counter32 &c);
57 /// syntax type
58 SmiUINT32 get_syntax();
60 /// create a new instance of this Value
61 SnmpSyntax *clone() const;
63 /// copy an instance of this Value
64 SnmpSyntax& operator=( SnmpSyntax &val);
66 /// overloaded assignment
67 Counter32& operator=( const Counter32 &uli);
69 /// overloaded assignment
70 Counter32& operator=( const unsigned long i);
72 /// otherwise, behave like an unsigned long int
73 operator unsigned long();
76 #endif // COUNTER_