summaryrefslogtreecommitdiff
path: root/replay/sv_basejob.h
blob: 35c1bfbbb57a1435140c3c052b0a12dfdf5b1ac3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//========= Copyright Valve Corporation, All rights reserved. ============//
//
//=======================================================================================//

#ifndef SV_BASEJOB_H
#define SV_BASEJOB_H

//----------------------------------------------------------------------------------------

#undef Yield

#include "spew.h"
#include "vstdlib/jobthread.h"

//----------------------------------------------------------------------------------------

class CBaseJob : public CJob,
				 public CBaseSpewer
{
public:
	CBaseJob( JobPriority_t priority = JP_NORMAL, ISpewer *pSpewer = g_pDefaultSpewer );

	enum Error_t
	{
		ERROR_NONE = -1,
	};

	const char *GetErrorStr() const { return m_szError; }

protected:
	void	SetError( int nError, const char *pError = NULL );

private:
	int				m_nError;
	char			m_szError[256];
};

//----------------------------------------------------------------------------------------

#endif // SV_BASEJOB_H