2009-07-14 00:45:15 +04:00
|
|
|
/*
|
|
|
|
* Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de.
|
2014-10-26 00:19:38 +04:00
|
|
|
* Copyright 2014, Rene Gollent, rene@gollent.com.
|
2009-07-14 00:45:15 +04:00
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
|
|
|
#ifndef SOURCE_LANGUAGE_H
|
|
|
|
#define SOURCE_LANGUAGE_H
|
|
|
|
|
|
|
|
|
|
|
|
#include <Referenceable.h>
|
|
|
|
|
|
|
|
|
2012-11-06 15:22:06 +04:00
|
|
|
class BString;
|
2009-07-14 00:45:15 +04:00
|
|
|
class SyntaxHighlighter;
|
2012-11-06 15:22:06 +04:00
|
|
|
class TeamTypeInformation;
|
|
|
|
class Type;
|
2014-10-26 00:19:38 +04:00
|
|
|
class Value;
|
2014-10-30 00:32:14 +03:00
|
|
|
class ValueNode;
|
|
|
|
class ValueNodeManager;
|
2009-07-14 00:45:15 +04:00
|
|
|
|
|
|
|
|
2010-12-16 16:50:30 +03:00
|
|
|
class SourceLanguage : public BReferenceable {
|
2009-07-14 00:45:15 +04:00
|
|
|
public:
|
|
|
|
virtual ~SourceLanguage();
|
|
|
|
|
|
|
|
virtual const char* Name() const = 0;
|
|
|
|
|
|
|
|
virtual SyntaxHighlighter* GetSyntaxHighlighter() const;
|
|
|
|
// returns a reference,
|
|
|
|
// may return NULL, if not available
|
2012-11-06 15:22:06 +04:00
|
|
|
|
2014-10-26 23:16:20 +03:00
|
|
|
virtual status_t ParseTypeExpression(const BString& expression,
|
2012-11-06 15:22:06 +04:00
|
|
|
TeamTypeInformation* info,
|
|
|
|
Type*& _resultType) const;
|
2014-10-26 00:19:38 +04:00
|
|
|
|
|
|
|
virtual status_t EvaluateExpression(const BString& expression,
|
2014-10-30 00:32:14 +03:00
|
|
|
type_code type, ValueNodeManager* manager,
|
|
|
|
Value*& _output, ValueNode*& _neededNode);
|
2009-07-14 00:45:15 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif // SOURCE_LANGUAGE_H
|