Website Summary Files Commits Branches @commit @diff @stats
path: root / src / String / String.h
diff options
context:
space:
mode:
Commitad9b755abb255ec0884b3d3091cb9514d8fd1381 (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-04-25 16:56:43 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-04-25 16:56:43 +0300
Filesa40b16ae3f2c8396308fe4e3fe3bf7a9249335cd /src/String/String.h
FMI-OOP-P1_TicketSystem-ad9b755abb255ec0884b3d3091cb9514d8fd1381.tar
FMI-OOP-P1_TicketSystem-ad9b755abb255ec0884b3d3091cb9514d8fd1381.tar.gz
FMI-OOP-P1_TicketSystem-ad9b755abb255ec0884b3d3091cb9514d8fd1381.zip
Parent8656048f5a03fc7808608aa4b5ee65590141f4d0 (diff)
Autocommit at 25.04.2022 @ 16:56
1 files changed, 26 insertions, 0 deletions
-rw-r--r--src/String/String.h26
diff --git a/src/String/String.h b/src/String/String.h
new file mode 100644
index 0000000..4accaef
--- /dev/null
+++ b/src/String/String.h
@@ -0,0 +1,26 @@
+#ifndef HEADER_STRING
+#define HEADER_STRING
+
+class String {
+ char* elems;
+ unsigned count;
+ unsigned length;
+
+ void free();
+ void copyFrom(const String& other);
+ void moveFrom(String&& other);
+
+public:
+ String();
+ String(const String& other);
+ String& operator=(const String& other);
+ ~String();
+
+ String(String&& other);
+ String& operator=(String&& other);
+
+ int compare(const String& other);
+ char operator[](unsigned index);
+};
+
+#endif