// CodeGear C++Builder
// Copyright (c) 1995, 2014 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'XLSFmlaDebugger5.pas' rev: 28.00 (Windows)

#ifndef Xlsfmladebugger5HPP
#define Xlsfmladebugger5HPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>	// Pascal unit
#include <SysInit.hpp>	// Pascal unit
#include <System.Classes.hpp>	// Pascal unit
#include <System.SysUtils.hpp>	// Pascal unit
#include <System.Contnrs.hpp>	// Pascal unit
#include <System.Math.hpp>	// Pascal unit
#include <Xc12Utils5.hpp>	// Pascal unit
#include <Xc12Manager5.hpp>	// Pascal unit
#include <XLSUtils5.hpp>	// Pascal unit
#include <XLSCellMMU5.hpp>	// Pascal unit
#include <XLSFormulaTypes5.hpp>	// Pascal unit
#include <XLSEvaluate5.hpp>	// Pascal unit
#include <XLSEvaluateFmla5.hpp>	// Pascal unit
#include <XLSDecodeFmla5.hpp>	// Pascal unit
#include <XLSEncodeFmla5.hpp>	// Pascal unit
#include <XLSFormula5.hpp>	// Pascal unit
#include <XLSFmlaDebugData5.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Xlsfmladebugger5
{
//-- type declarations -------------------------------------------------------
class DELPHICLASS TFmlaDebugger;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TFmlaDebugger : public System::TObject
{
	typedef System::TObject inherited;
	
protected:
	Xc12manager5::TXc12Manager* FManager;
	int FSheetIndex;
	int FCol;
	int FRow;
	Xlsformulatypes5::TXLSPtgs *FPtgs;
	int FPtgsSz;
	System::Classes::TStringList* FStack;
	Xlsfmladebugdata5::TFmlaDebugItems* FItems;
	Xlsfmladebugdata5::TFmlaDebugItem* FCurrItem;
	System::UnicodeString FFormula;
	System::Classes::TStringList* FFormulas;
	System::UnicodeString FLastEval;
	int FMaxSteps;
	int FCurrSteps;
	System::UnicodeString __fastcall GetFormulaValue(const Xlsevaluate5::TXLSFormulaValue &AFV);
	void __fastcall CollectFormulas(void);
	void __fastcall DumpStack(Xlsevaluatefmla5::TValueStack* AStack);
	void __fastcall DumpFormulas(void);
	System::UnicodeString __fastcall Decode(Xlsformulatypes5::PXLSPtgs APtgs, Xlsformulatypes5::PXLSPtgs AStopPtgs, int APtgsSz);
	int __fastcall Encode(const System::UnicodeString AFormula, /* out */ Xlsformulatypes5::PXLSPtgs &APtgs);
	bool __fastcall EvaluateSteps(const int ASteps);
	
public:
	__fastcall TFmlaDebugger(Xc12manager5::TXc12Manager* const AManager, const int ASheetIndex, const int ACol, const int ARow);
	__fastcall virtual ~TFmlaDebugger(void);
	bool __fastcall AtFirst(void);
	bool __fastcall AtLast(void);
	void __fastcall MoveNext(void);
	void __fastcall MovePrev(void);
	void __fastcall MoveSteps(const int ASteps);
	int __fastcall StepsToPos(const int APos);
	System::UnicodeString __fastcall LastResult(void);
	__property System::UnicodeString Formula = {read=FFormula};
	__property System::Classes::TStringList* Formulas = {read=FFormulas};
	__property System::UnicodeString LastEval = {read=FLastEval};
	__property System::Classes::TStringList* Stack = {read=FStack};
	__property Xlsfmladebugdata5::TFmlaDebugItem* CurrItem = {read=FCurrItem};
};

#pragma pack(pop)

//-- var, const, procedure ---------------------------------------------------
}	/* namespace Xlsfmladebugger5 */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_XLSFMLADEBUGGER5)
using namespace Xlsfmladebugger5;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// Xlsfmladebugger5HPP
