2009-07-17 05:54:43 +04:00
|
|
|
/*
|
|
|
|
* Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de.
|
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
|
|
|
#ifndef VARIABLE_H
|
|
|
|
#define VARIABLE_H
|
|
|
|
|
|
|
|
|
|
|
|
#include <String.h>
|
|
|
|
|
|
|
|
#include <Referenceable.h>
|
|
|
|
|
|
|
|
|
2013-03-30 05:04:20 +04:00
|
|
|
class CpuState;
|
2009-07-19 03:52:16 +04:00
|
|
|
class ObjectID;
|
2009-07-17 05:54:43 +04:00
|
|
|
class Type;
|
|
|
|
class ValueLocation;
|
|
|
|
|
|
|
|
|
2010-12-16 16:50:30 +03:00
|
|
|
class Variable : public BReferenceable {
|
2009-07-17 05:54:43 +04:00
|
|
|
public:
|
2009-07-19 03:52:16 +04:00
|
|
|
Variable(ObjectID* id, const BString& name,
|
2013-03-30 05:04:20 +04:00
|
|
|
Type* type, ValueLocation* location,
|
|
|
|
CpuState* state = NULL);
|
2009-07-17 05:54:43 +04:00
|
|
|
~Variable();
|
|
|
|
|
2009-07-19 03:52:16 +04:00
|
|
|
ObjectID* ID() const { return fID; }
|
2009-07-17 05:54:43 +04:00
|
|
|
const BString& Name() const { return fName; }
|
|
|
|
Type* GetType() const { return fType; }
|
|
|
|
ValueLocation* Location() const { return fLocation; }
|
2013-03-30 05:04:20 +04:00
|
|
|
CpuState* GetCpuState() const { return fCpuState; }
|
2009-07-17 05:54:43 +04:00
|
|
|
|
|
|
|
private:
|
2009-07-19 03:52:16 +04:00
|
|
|
ObjectID* fID;
|
2009-07-17 05:54:43 +04:00
|
|
|
BString fName;
|
|
|
|
Type* fType;
|
|
|
|
ValueLocation* fLocation;
|
2013-03-30 05:04:20 +04:00
|
|
|
CpuState* fCpuState;
|
2009-07-17 05:54:43 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif // VARIABLE_H
|