Main Types added

This commit is contained in:
2018-03-21 08:02:58 +03:00
parent a6f2243e59
commit ea6e35e387
3 changed files with 66 additions and 0 deletions

View File

@@ -0,0 +1,56 @@
unit RuntimeBuilder.Types;
interface
const
CRTBCallTypeNil=$0;
CRTBCallTypeRegister=$1;
CRTBCallTypeStdCall=$2;
CRTBCallTypeCdecl=$3;
CRTBCallTypeClrcall=$4;
CRTBCallTypeThiscall=$5;
CRTBCallTypeVectorcall=$6;
CRTBCallTypeCFastCall=$7;
CRTBCallTypeFortran=$8;
CRTBCallTypeSyscall=$9;
CRTBCallType64Call=$40;
CRTBCallTypeDefault=$80;
type
TRTBCompliter=class;
TRTBCallType=CRTBCallTypeNil..CRTBCallTypeDefault;
TRTBSource=class abstract
private
Compliter:TRTBCompliter;
function GetText:string;virtual;abstract;
procedure SetText(S:string);virtual;abstract;
public
procedure Complete();virtual;abstract;
property Text:string read GetText write SetText;
end;
TRTBFunc=class abstract
public
function Call(args:array of const;CallType:TRTBCallType=CRTBCallTypeDefault):Variant;virtual;abstract;
end;
TRTBLib=class abstract
private
function GetFuntion(Name:string):TRTBFunc;virtual;abstract;
public
property Funtion[Name:string]:TRTBFunc read GetFuntion;
end;
TRTBCompliter=class abstract
public
function LoadLib(Name:string):TRTBLib;virtual;abstract;
function GenSrc():TRTBSource;virtual;abstract;
function CompleteFunc(Source:TRTBSource;args:array of const):TRTBFunc;virtual;abstract;
function CompleteLib(Source:TRTBSource;args:array of const):TRTBLib;virtual;abstract;
end;
implementation
end.

View File

@@ -0,0 +1,9 @@
unit RuntimeBuilder;
interface
uses RuntimeBuilder.Types;
implementation
end.