Summary Files Commits Branches @commit @diff @stats
path: root / Year 1 / Object-oriented Programming / Solutions Sem. 08 / ex3 / DynStr.h
blob: 5978a728e02d45c4bf920378a9588a0dd6fb3786 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class DynStr {
	char* str;
	int length;

	void free();
	void copyFrom(const DynStr& other);

public:
	DynStr();
	DynStr(const char* str);

	DynStr(const DynStr& copy);
	DynStr& operator=(const DynStr& other);
	~DynStr();

	const char* get_str() const;
	int compare(const char* other) const;
};