Skip to content
Permalink
af68184db9
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
40 lines (30 sloc) 764 Bytes
/*
*
* Stores the interface for building a sensor thread
* implementation.
*
*/
#ifndef SENSOR_INTERFACE_HPP
#define SENSOR_INTERFACE_HPP
#include <stdio.h>
#include <Windows.h>
class IOProcessor
{
public:
// Thread routine for implementation to override
virtual VOID threadRuntime() = 0;
// Thread initialization, should not be called directly!
static DWORD threadInit(LPVOID pIOProcessor);
// Async control
UINT8 startThread(LPVOID pThreadArgs);
BOOL waitForThread();
// Sync control
BOOLEAN bufferDataAvailable();
SIZE_T getBufferData(LPCSTR* bufferKeyArray, LPCSTR* bufferValueArray);
VOID setDataStoreValue(LPCSTR key, LPCVOID value, SIZE_T valueSize);
protected:
LPCVOID threadArgs;
DWORD dwThreadId;
HANDLE hThread;
};
#endif