summaryrefslogtreecommitdiff
path: root/src/group.c
diff options
context:
space:
mode:
authorLouie S <louie@example.com>2023-07-03 11:30:38 -0700
committerLouie S <louie@example.com>2023-07-03 11:30:38 -0700
commitded510aedc6d1df4b34e1cca07847098fd94198b (patch)
treed0f089e68e94cccca9cd3e1bf23e274505f710c1 /src/group.c
parenta3c635bc459ea6e05c62868ddd0ef3a097ae05dc (diff)
Add id to structs
Diffstat (limited to 'src/group.c')
-rw-r--r--src/group.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/group.c b/src/group.c
index db387e0..33307ee 100644
--- a/src/group.c
+++ b/src/group.c
@@ -2,6 +2,11 @@
#include "group.h"
+// getters
+int group_get_id(Group *g) {
+ return g->id;
+}
+
char *group_get_name(Group *g) {
return g->name;
}
@@ -14,6 +19,11 @@ char *group_get_url(Group *g) {
return g->url;
}
+// setters
+void group_set_id(Group *g, int id) {
+ g->id = id;
+}
+
void group_set_name(Group *g, char *name) {
strcpy(g->name, name);
}