/****************************************************************************
** Interface definition generated for ActiveQt project
**
**     'C:\builds\build-lnr-fr-com-Desktop_Qt_5_5_1_MSVC2010_32bit-Release\release\lnrfrcomax.dll'
**
** Created:  Чт ноя 3 10:26:53 2022
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

import "ocidl.idl";
#include <olectl.h>

[
	uuid(CEF5DAA8-2297-4A45-9CD5-0E9EF3C32F46),
	version(1.0),
	helpstring("lnrfrcomax 1.0 Type Library")
]
library lnrfrcomaxLib
{
	importlib("stdole32.tlb");
	importlib("stdole2.tlb");

	/************************************************************************
	** If this causes a compile error in MIDL you need to upgrade the
	** Platform SDK you are using. Download the SDK from msdn.microsoft.com
	** and make sure that both the system and the Visual Studio environment
	** use the correct files.
	**
	************************************************************************/

	[uuid(34030f30-e359-4fe6-ab82-39766f5d91ee)]
	struct QRect {
		int left;
		int top;
		int right;
		int bottom;
	};

	[uuid(cb5f84b3-29e5-491d-ba18-5472488eefba)]
	struct QSize {
		int width;
		int height;
	};

	[uuid(3be838a3-3fac-bfc4-4c6c-37c44d030252)]
	struct QPoint {
		int x;
		int y;
	};

	/* Forward declaration of classes that might be used as parameters */

	coclass AxFrWrapper;
	coclass ModelData;
	coclass FrStatus;
	coclass CycleStatus;
	coclass Tax;
	coclass RegData;
	coclass Counters;
	coclass ReceiptCounters;
	coclass GrossCounters;
	coclass ReceiptGrossCounters;
	coclass SectionCounters;
	coclass ReceiptOperation;

	enum MousePointer {
		ArrowCursor             = 0,
		UpArrowCursor           = 1,
		CrossCursor             = 2,
		WaitCursor              = 3,
		IBeamCursor             = 4,
		SizeVerCursor           = 5,
		SizeHorCursor           = 6,
		SizeBDiagCursor         = 7,
		SizeFDiagCursor         = 8,
		SizeAllCursor           = 9,
		BlankCursor             = 10,
		SplitVCursor            = 11,
		SplitHCursor            = 12,
		PointingHandCursor      = 13,
		ForbiddenCursor         = 14,
		WhatsThisCursor         = 15,
		BusyCursor	= 16
	};

	enum FocusPolicy {
		NoFocus             = 0,
		TabFocus            = 1,
		ClickFocus          = 2,
		StrongFocus         = 11,
		WheelFocus          = 15
	};


	[
		uuid(DC52824B-5938-4447-8466-978CA36F0FA3),
		helpstring("Tax Interface")
	]
	dispinterface ITax
	{
	properties:
		[id(1)] unsigned char type;
		[id(2)] int rate;
		[id(3)] BSTR name;

	methods:
	};

	[
		aggregatable,
		helpstring("Tax Class"),
		uuid(1F32B513-9F25-48E6-8CF9-CAE0348A7E34), 
		noncreatable
	]
	coclass Tax
	{
		[default] dispinterface ITax;
	};

	[
		uuid(D740C8F1-10F6-4CAE-9B38-A92CB6F41B61),
		helpstring("ReceiptCounters Interface")
	]
	dispinterface IReceiptCounters
	{
	properties:
		[id(1), readonly] unsigned char type;
		[id(2), readonly] unsigned int receipts;
		[id(3), readonly] CY totalAmount;
		[id(4), readonly] CY cash;
		[id(5), readonly] CY card;
		[id(6), readonly] CY tax1;
		[id(7), readonly] CY tax2;
		[id(8), readonly] CY tax3;
		[id(9), readonly] CY tax4;
		[id(10), readonly] CY tax5;
		[id(11), readonly] double totalAmountR;
		[id(12), readonly] double cashR;
		[id(13), readonly] double cardR;
		[id(14), readonly] double tax1R;
		[id(15), readonly] double tax2R;
		[id(16), readonly] double tax3R;
		[id(17), readonly] double tax4R;
		[id(18), readonly] double tax5R;
		[id(19), readonly] BSTR totalAmountStr;
		[id(20), readonly] BSTR cashStr;
		[id(21), readonly] BSTR cardStr;
		[id(22), readonly] BSTR tax1Str;
		[id(23), readonly] BSTR tax2Str;
		[id(24), readonly] BSTR tax3Str;
		[id(25), readonly] BSTR tax4Str;
		[id(26), readonly] BSTR tax5Str;

	methods:
	};

	[
		aggregatable,
		helpstring("ReceiptCounters Class"),
		uuid(CD7EFE43-63F2-4D42-9AAA-AEBF510365F3), 
		noncreatable
	]
	coclass ReceiptCounters
	{
		[default] dispinterface IReceiptCounters;
	};

	[
		uuid(0F2AC7FB-1E5E-4BB9-95C5-BECAC352CE61),
		helpstring("ReceiptGrossCounters Interface")
	]
	dispinterface IReceiptGrossCounters
	{
	properties:
		[id(1), readonly] unsigned char type;
		[id(2), readonly] unsigned int receipts;
		[id(3), readonly] CY totalAmount;
		[id(4), readonly] CY cash;
		[id(5), readonly] CY card;
		[id(6), readonly] double totalAmountR;
		[id(7), readonly] double cashR;
		[id(8), readonly] double cardR;
		[id(9), readonly] BSTR totalAmountStr;
		[id(10), readonly] BSTR cashStr;
		[id(11), readonly] BSTR cardStr;

	methods:
	};

	[
		aggregatable,
		helpstring("ReceiptGrossCounters Class"),
		uuid(1C8C36B5-2AC5-41CA-90FE-3A685929049F), 
		noncreatable
	]
	coclass ReceiptGrossCounters
	{
		[default] dispinterface IReceiptGrossCounters;
	};


	[
		uuid(E328C14C-CCEB-499F-9500-62C32731C94A),
		helpstring("AxFrWrapper Interface")
	]
	dispinterface IAxFrWrapper
	{
	properties:
		[id(1)] BSTR portName;
		[id(2)] int cashierNumber;
		[id(3)] unsigned int cashierPassword;
		[id(4), readonly] BSTR lastCommandError;
		[id(5), readonly] BSTR libVersion;

	methods:
		[id(6)] int getVersion([in,out] BSTR *p_version);
		[id(7)] int getSerial([in] ModelData* p_md);
		[id(8)] int getFrStatus([in] FrStatus* p_st);
		[id(9)] int getCycleStatus([in] CycleStatus* p_st);
		[id(10)] int cancelDoc();
		[id(11)] int sendDocData([in] SAFEARRAY(BYTE) p_data);
		[id(12)] int readRegTlv([in] unsigned short p_tag, [in,out] unsigned int *p_outTag, [in,out] unsigned int *p_outLen, [in,out] SAFEARRAY(BYTE) *p_outValue);
		[id(13)] int readCurrentRegData([in] RegData* p_rd);
		[id(14)] int getCycleCounters([in] Counters* p_c);
		[id(15)] int getRegCounters([in] Counters* p_c);
		[id(16)] int getTotalCounters([in] GrossCounters* p_c);
		[id(17)] int getSectionsCounters([in] SectionCounters* p_c);
		[id(18)] int startFiscalization([in] BSTR p_cashier);
		[id(19)] int completeFiscalization([in] BSTR p_inn, [in] BSTR p_regNumber, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fisc, [in,out] DATE *p_dt);
		[id(20)] int startCycleOpening([in] BSTR p_cashier);
		[id(21)] int completeCycleOpening([in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt);
		[id(22)] int startIntroduction([in] BSTR p_cashier);
		[id(23)] int completeIntroduction([in] CY p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] CY *p_cash);
		[id(24)] int completeIntroductionR([in] double p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] double *p_cash);
		[id(25)] int completeIntroductionStr([in] BSTR p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] BSTR *p_cash);
		[id(26)] int startPayout([in] BSTR p_cashier);
		[id(27)] int completePayout([in] CY p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] CY *p_cash);
		[id(28)] int completePayoutR([in] double p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] double *p_cash);
		[id(29)] int completePayoutStr([in] BSTR p_amount, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt, [in,out] BSTR *p_cash);
		[id(30)] int startCycleClosing([in] BSTR p_cashier);
		[id(31)] int completeCycleClosing([in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt);
		[id(32)] int startArchiveClosing([in] BSTR p_cashier);
		[id(33)] int completeArchiveClosing([in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] DATE *p_dt);
		[id(34)] int startReceipt([in] unsigned char p_type, [in] BSTR p_cashier);
		[id(35)] int addReceiptOperation([in] ReceiptOperation* p_op);
		[id(36)] int addReceiptTextParam([in] BSTR p_value);
		[id(37)] int completeReceipt([in] CY p_cash, [in] CY p_card, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] unsigned int *p_receipt, [in,out] DATE *p_dt, [in,out] CY *p_amount, [in,out] CY *p_change);
		[id(38)] int completeReceiptR([in] double p_cash, [in] double p_card, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] unsigned int *p_receipt, [in,out] DATE *p_dt, [in,out] double *p_amount, [in,out] double *p_change);
		[id(39)] int completeReceiptStr([in] BSTR p_cash, [in] BSTR p_card, [in,out] unsigned int *p_cycle, [in,out] unsigned int *p_fd, [in,out] unsigned int *p_fiscCode, [in,out] unsigned int *p_receipt, [in,out] DATE *p_dt, [in,out] BSTR *p_amount, [in,out] BSTR *p_change);
		[id(40)] int getOpenedDocData([in,out] unsigned int *p_docType, [in,out] unsigned int *p_recType, [in,out] unsigned int *p_receipt, [in,out] unsigned int *p_operations, [in,out] CY *p_amount);
		[id(41)] int getOpenedDocDataR([in,out] unsigned int *p_docType, [in,out] unsigned int *p_recType, [in,out] unsigned int *p_receipt, [in,out] unsigned int *p_operations, [in,out] double *p_amount);
		[id(42)] int getOpenedDocDataStr([in,out] unsigned int *p_docType, [in,out] unsigned int *p_recType, [in,out] unsigned int *p_receipt, [in,out] unsigned int *p_operations, [in,out] BSTR *p_amount);
		[id(43)] int readCatalogEntity([in] unsigned char p_type, [in] unsigned char p_number, [in,out] SAFEARRAY(BYTE) *p_out_);
		[id(44)] int writeCatalogEntity([in] unsigned char p_type, [in] SAFEARRAY(BYTE) p_in);
		[id(45)] int readDt([in,out] DATE *p_dt);
		[id(46)] int writeDt([in] DATE p_dt);
		[id(47)] int readPrinterParam([in] unsigned char p_type, [in,out] SAFEARRAY(BYTE) *p_out_);
		[id(48)] int writePrinterParam([in] unsigned char p_type, [in] SAFEARRAY(BYTE) p_in);
		[id(49)] int printLine([in] char p_ls, [in] char p_just, [in] char p_font, [in] char p_flags, [in] BSTR p_text);
		[id(50)] int printRaw([in] SAFEARRAY(BYTE) p_raw);
		[id(51)] int printCut();
		[id(52)] int printReport([in] int p_type, [in] SAFEARRAY(BYTE) p_params);
		[id(53)] int printXReport();
		[id(54)] int printRegReport();
		[id(55)] int printGrossReport();
		[id(56)] int printSectionsReport();
		[id(57)] int printPeriodicReport([in] DATE p_from, [in] DATE p_to);
		[id(58)] int printReportByCycles([in] unsigned short p_from, [in] unsigned short p_to);
		[id(59)] int printDocCopy([in] int p_fd);
		[id(60)] int printControlTape([in] int p_fd, [in,out] unsigned int *p_outFd);
	};

	[
		uuid(25DF0442-2C3F-4CE8-987E-1DBC14BEF3BF),
		helpstring("AxFrWrapper Events Interface")
	]
	dispinterface IAxFrWrapperEvents
	{
	properties:
	methods:
	/****** Signal parameter uses unsupported datatype
		[id(1)] void destroyed([in] QObject p0);
	******/
		[id(2)] void destroyed_1();
		[id(3)] void objectNameChanged([in] BSTR p_objectName);
		[id(4)] void portNameChanged();
		[id(5)] void cashierNumberChanged();
		[id(6)] void cashierPasswordChanged();
	};

	[
		aggregatable,
		appobject,
		helpstring("AxFrWrapper Class"),
		uuid(FE3DAEF0-5F66-4C22-A18D-D7A849F45347)
	]
	coclass AxFrWrapper
	{
		[default] dispinterface IAxFrWrapper;
		[default, source] dispinterface IAxFrWrapperEvents;
	};

	[
		uuid(B8F172F7-6E1B-4ABA-805B-1483E456FE22),
		helpstring("ModelData Interface")
	]
	dispinterface IModelData
	{
	properties:
		[id(1)] int model;
		[id(2)] BSTR modelName;
		[id(3)] BSTR serial;

	methods:
	};

	[
		aggregatable,
		helpstring("ModelData Class"),
		uuid(9C70FC99-501D-40C1-A524-E908204E02B8)
	]
	coclass ModelData
	{
		[default] dispinterface IModelData;
	};

	[
		uuid(E25236F7-72A8-4EAB-A4BC-41A9914820B0),
		helpstring("FrStatus Interface")
	]
	dispinterface IFrStatus
	{
	properties:
		[id(1), readonly] BSTR serial;
		[id(2), readonly] unsigned short flags;
		[id(3), readonly] unsigned char curDocType;
		[id(4), readonly] unsigned int lastDoc;
		[id(5), readonly] DATE lastDocDt;
		[id(6), readonly] unsigned short cycle;
		[id(7), readonly] unsigned short receipt;
		[id(8), readonly] unsigned int docsAvailable;
		[id(9), readonly] unsigned char regsCount;
		[id(10), readonly] unsigned char totalRegsCount;
		[id(11), readonly] unsigned char avalilableRegsCount;
		[id(12), readonly] BSTR descr;

	methods:
	};

	[
		aggregatable,
		helpstring("FrStatus Class"),
		uuid(C87607D2-F98E-46BC-888B-2ABA5A8E04A3)
	]
	coclass FrStatus
	{
		[default] dispinterface IFrStatus;
	};

	[
		uuid(F8CD25A5-AC06-4E82-9D99-D0646811E942),
		helpstring("CycleStatus Interface")
	]
	dispinterface ICycleStatus
	{
	properties:
		[id(1), readonly] VARIANT_BOOL isOpen;
		[id(2), readonly] unsigned short cycle;
		[id(3), readonly] unsigned short receipt;
		[id(4), readonly] unsigned int firstCycleDoc;
		[id(5), readonly] DATE openDt;
		[id(6), readonly] unsigned int lastCycleDoc;
		[id(7), readonly] DATE closeDt;
		[id(8), readonly] CY cash;
		[id(9), readonly] double cashR;
		[id(10), readonly] BSTR cashStr;
		[id(11), readonly] BSTR descr;

	methods:
	};

	[
		aggregatable,
		helpstring("CycleStatus Class"),
		uuid(763D8050-EBE1-445A-8FB8-57F0828AB4C5)
	]
	coclass CycleStatus
	{
		[default] dispinterface ICycleStatus;
	};

	[
		uuid(F592ED59-0906-433A-A152-9B9B04AE4B99),
		helpstring("RegData Interface")
	]
	dispinterface IRegData
	{
	properties:
		[id(1)] BSTR regNumber;
		[id(2)] BSTR inn;
		[id(3)] BSTR orgName;
		[id(4)] BSTR orgType;
		[id(5)] BSTR orgAddress;
		[id(6), readonly] DATE regTime;
		[id(7), readonly] VARIANT_BOOL hasValidTax;
		[id(8), readonly] BSTR descr;

	methods:
		[id(9)] Tax* getTax([in] int p_idx);
		[id(10)] void setTax([in] int p_idx, [in] Tax* p_tax);
	};

	[
		aggregatable,
		helpstring("RegData Class"),
		uuid(59CC5F1D-2E19-4F28-8E7B-D05CFE2ECC42)
	]
	coclass RegData
	{
		[default] dispinterface IRegData;
	};

	[
		uuid(3F16ABA7-14FA-49CC-96F7-BD01FDDBE7C4),
		helpstring("Counters Interface")
	]
	dispinterface ICounters
	{
	properties:
		[id(1), readonly] unsigned short cycle;
		[id(2), readonly] unsigned short introductions;
		[id(3), readonly] unsigned short payouts;
		[id(4), readonly] CY introductionsAmount;
		[id(5), readonly] CY payoutsAmount;
		[id(6), readonly] double introductionsAmountR;
		[id(7), readonly] double payoutsAmountR;
		[id(8), readonly] BSTR introductionsAmountStr;
		[id(9), readonly] BSTR payoutsAmountStr;
		[id(10), readonly] unsigned int receipts;
		[id(11), readonly] CY totalCash;
		[id(12), readonly] ReceiptCounters* saleCounters;
		[id(13), readonly] ReceiptCounters* purchaseCounters;
		[id(14), readonly] ReceiptCounters* saleReturnCounters;
		[id(15), readonly] ReceiptCounters* purchaseReturnCounters;
		[id(16), readonly] BSTR cycleCountersDescr;
		[id(17), readonly] BSTR regCountersDescr;

	methods:
	};

	[
		aggregatable,
		helpstring("Counters Class"),
		uuid(05955401-B1BA-410B-A452-DF280389DACD)
	]
	coclass Counters
	{
		[default] dispinterface ICounters;
	};

	[
		uuid(A0B13103-482B-4470-A090-117E263F8C8C),
		helpstring("GrossCounters Interface")
	]
	dispinterface IGrossCounters
	{
	properties:
		[id(1), readonly] unsigned short cycle;
		[id(2), readonly] unsigned short introductions;
		[id(3), readonly] unsigned short payouts;
		[id(4), readonly] CY introductionsAmount;
		[id(5), readonly] CY payoutsAmount;
		[id(6), readonly] double introductionsAmountR;
		[id(7), readonly] double payoutsAmountR;
		[id(8), readonly] BSTR introductionsAmountStr;
		[id(9), readonly] BSTR payoutsAmountStr;
		[id(10), readonly] unsigned int receipts;
		[id(11), readonly] ReceiptGrossCounters* saleCounters;
		[id(12), readonly] ReceiptGrossCounters* purchaseCounters;
		[id(13), readonly] ReceiptGrossCounters* saleReturnCounters;
		[id(14), readonly] ReceiptGrossCounters* purchaseReturnCounters;
		[id(15), readonly] BSTR descr;

	methods:
	};

	[
		aggregatable,
		helpstring("GrossCounters Class"),
		uuid(0E146367-AAA6-4C8C-9398-59A9286A3508)
	]
	coclass GrossCounters
	{
		[default] dispinterface IGrossCounters;
	};

	[
		uuid(EE748C61-68A8-4B32-8A51-4E7B02BC87E6),
		helpstring("SectionCounters Interface")
	]
	dispinterface ISectionCounters
	{
	properties:

	methods:
		[id(1)] CY getAmount([in] unsigned char p_recType, [in] unsigned char p_section);
	};

	[
		aggregatable,
		helpstring("SectionCounters Class"),
		uuid(45068C68-8A9A-453C-801F-05E8B595D5D0)
	]
	coclass SectionCounters
	{
		[default] dispinterface ISectionCounters;
	};

	[
		uuid(93D2C8BE-6E66-4F37-AABD-D08120DC9D2E),
		helpstring("ReceiptOperation Interface")
	]
	dispinterface IReceiptOperation
	{
	properties:
		[id(1)] BSTR mainCode;
		[id(2)] BSTR barcode;
		[id(3)] BSTR name;
		[id(4)] BSTR unitName;
		[id(5)] unsigned char section;
		[id(6)] unsigned char taxNumber;
		[id(7)] unsigned char discountNumber;
		[id(8)] CY price;
		[id(9)] double priceR;
		[id(10)] BSTR priceStr;
		[id(11)] CY discount;
		[id(12)] double discountR;
		[id(13)] BSTR discountStr;
		[id(14)] double quantity;
		[id(15)] BSTR quantityStr;
		[id(16)] BSTR textParam;

	methods:
	};

	[
		aggregatable,
		helpstring("ReceiptOperation Class"),
		uuid(A1B856AC-D6C2-4D6A-9084-0242A2C3C718)
	]
	coclass ReceiptOperation
	{
		[default] dispinterface IReceiptOperation;
	};
};
