Skip to content

Commit

Permalink
🧹 chore: added abstract data wrapper class (#83)
Browse files Browse the repository at this point in the history
[CHORE] Abstract Data Wrapper for Streaming Services
  • Loading branch information
Sclafus authored Jun 23, 2023
2 parents 492d4d7 + 61e39b1 commit 56534fb
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ qt_standard_project_setup()
# ===========================Including Project Files===========================
set(FORMS_DIR "${CMAKE_CURRENT_SOURCE_DIR}/forms")
set(SOURCE_DIR "${CMAKE_SOURCE_DIR}/src")
set(SOURCE_TWITCH_DIR "${CMAKE_SOURCE_DIR}/src/twitch")
set(SOURCE_STREAMING_SERVICES_DIR "${CMAKE_SOURCE_DIR}/src/services/streaming")
set(SOURCE_TWITCH_DIR "${CMAKE_SOURCE_DIR}/src/services/streaming/twitch")
set(SOURCE_GOSU_DIR "${CMAKE_SOURCE_DIR}/src/gosu")
set(SOURCE_OSUIRC_DIR "${CMAKE_SOURCE_DIR}/src/osuirc")
set(SOURCE_UTILS_DIR "${CMAKE_SOURCE_DIR}/src/utils")
Expand All @@ -30,6 +31,7 @@ set(SOURCE_ABOUT_DIR "${CMAKE_SOURCE_DIR}/src/about")
include_directories(
${FORMS_DIR}
${SOURCE_DIR}
${SOURCE_STREAMING_SERVICES_DIR}
${SOURCE_TWITCH_DIR}
${SOURCE_GOSU_DIR}
${SOURCE_OSUIRC_DIR}
Expand All @@ -46,6 +48,8 @@ include_directories(

file(GLOB_RECURSE SOURCES
${FORMS_DIR}/*.cpp
${SOURCE_STREAMING_SERVICES_DIR}/*.h
${SOURCE_STREAMING_SERVICES_DIR}/*.cpp
${SOURCE_TWITCH_DIR}/*.h
${SOURCE_TWITCH_DIR}/*.cpp
${SOURCE_GOSU_DIR}/*.h
Expand Down
13 changes: 13 additions & 0 deletions src/services/streaming/streamingServiceDataWrapper.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#ifndef STREAMINGSERVICEDATAWRAPPER_H
#define STREAMINGSERVICEDATAWRAPPER_H

#include <QString>

class StreamingServiceDataWrapper
{
public:
virtual QString getMessage() = 0;
virtual QString getUsername() = 0;
};

#endif // STREAMINGSERVICEDATAWRAPPER_H
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
#define TWITCHDATAWRAPPER_H

#include <QString>
#include "streamingServiceDataWrapper.h"

class TwitchDataWrapper
class TwitchDataWrapper : public StreamingServiceDataWrapper
{
public:
TwitchDataWrapper(QString &data);
Expand Down

0 comments on commit 56534fb

Please sign in to comment.