Website Summary Files Commits Branches @commit @diff @stats
path: root / Sem. 07 / MyString / MyString.h
blob: 77b46fac1464fc55bd190ac0fa7587eecbd17a27 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#pragma once


class MyString
{
	char* str;
	size_t size;

	void copyFrom(const MyString& other);
	void free();
public:
	MyString();
	MyString(const char*);

	MyString(const MyString&);
	MyString& operator=(const MyString& other);
	~MyString();

	size_t getSize() const;
	void concat(const MyString& other);

	const char* c_str() const;
};
//MyString name = "sdfsdf"