[go: up one dir, main page]

Menu

[r144]: / var.h  Maximize  Restore  History

Download this file

57 lines (45 with data), 1.2 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#pragma once
using namespace std;
enum vtype { EMP, DW, STR, FLT };
typedef unsigned long ulong;
class var
{
typedef unsigned long ulong;
public:
ulong dw;
string str;
long double flt;
vtype vt;
bool isbuf;
int size;
var();
var(const var& rhs);
var(string& rhs);
var(ulong rhs);
var(int rhs);
var(long double rhs);
// less than zero this < rhs
// zero this == rhs
// greater than zero this > rhs
int compare(const var& rhs) const;
int compare(const string& rhs) const;
int compare(const ulong& rhs) const;
int compare(const int& rhs) const;
int compare(const long double& rhs) const;
string strclean(void);
string strbuffhex(void);
string strbuff(void);
var& operator=(const var& rhs);
var& operator=(const string& rhs);
var& operator=(const ulong& rhs);
var& operator=(const int& rhs);
var& operator=(unsigned short& rhs);
var& operator=(unsigned char& rhs);
var& operator=(const long double& rhs);
var& operator+=(const var& rhs);
var& operator+=(const string& rhs);
var& operator+=(const ulong& rhs);
var& operator+=(const int& rhs);
var& operator+=(const long double& rhs);
void resize(ulong newsize);
};