mirror of
https://git.suyu.dev/suyu/discord-rpc.git
synced 2026-01-07 23:18:55 +01:00
* Choose pipe number on initialize * Get pipe from base connection instance * UE4 support * Warnings as errors yelling * Fix windows connection * Oops all variables * maybe this fixes it * This one actually works!!!! * Fix double function declaration
19 lines
461 B
C
19 lines
461 B
C
#pragma once
|
|
|
|
// This is to wrap the platform specific kinds of connect/read/write.
|
|
|
|
#include <stdint.h>
|
|
#include <stdlib.h>
|
|
|
|
// not really connectiony, but need per-platform
|
|
int GetProcessId();
|
|
|
|
struct BaseConnection {
|
|
static BaseConnection* Create();
|
|
static void Destroy(BaseConnection*&);
|
|
bool isOpen{false};
|
|
bool Open(int pipe);
|
|
bool Close();
|
|
bool Write(const void* data, size_t length);
|
|
bool Read(void* data, size_t length);
|
|
};
|