Gorilla.Script.Parser
Unit Gorilla.Script.Parser.pasClasses
- TGorillaScriptParser = class ( TObject )
Constants
- const GORILLA_SCRIPT_UNIT_SYSTEM : string = "";
TGorillaScriptParser
Custom parser class for Gorilla3D languages.
Ancestors
Members
Fields
- protected FEngine :
TComponent
- protected FFormat :
TFormatSettings
- protected FUnitOrderIndex :
Integer
- protected FSystemUnit :
TGorillaScriptNativeUnit
- protected FUnitEntities :
TGorillaScriptUnitEntities
Methods
- public constructor Create ( const AEngine : TComponent ) ;
- public destructor Destroy ( ) ;
- protected function GetCurrent ( ) : Pointer ; abstract virtual;
- protected function GetCurrentFile ( ) : string ; abstract virtual;
- protected function GetCurrentCharPos ( ) : TPoint ; abstract virtual;
- protected function GetCurrentLine ( ) : Integer ; abstract virtual;
- protected procedure DoOnUnitEntityNotify ( ASender : TObject; const AItem : TGorillaScriptCustomUnitEntity; AAction : TCollectionNotification ) ;
- protected procedure DeclareDefaultClasses
(
)
;
abstract virtual;
This protected method declares default types like String, Int, Double or Boolean. All simple types are added to the default "System" namespace.
- protected procedure RegisterNativeEnums
(
const
AEnums :
TArray<Gorilla.Script.Types.TGorillaScriptRegisteredType>
)
;
abstract virtual;
Override this method to register native enumeration types depending on the used parser.
- protected procedure RegisterNativeSets
(
const
ASets :
TArray<Gorilla.Script.Types.TGorillaScriptRegisteredType>
)
;
abstract virtual;
Override this method to register native set types depending on the used parser.
- protected procedure RegisterNativeStructs
(
const
AStructs :
TArray<Gorilla.Script.Types.TGorillaScriptRegisteredType>
)
;
abstract virtual;
Override this method to register native records depending on the used parser.
- protected procedure RegisterNativeInterfaces
(
const
AIntfs :
TArray<System.string>
)
;
abstract virtual;
Override this method to register native classes depending on the used parser.
- protected procedure RegisterNativeClasses
(
const
AClasses :
TArray<System.TClass>
)
;
abstract virtual;
Override this method to register native classes depending on the used parser.
- public function LoadUnitFromFile ( const AFilename : string ) : TGorillaScriptUnit ; virtual;
- public function LoadUnitFromStream ( const AStream : TStream ) : TGorillaScriptUnit ; abstract virtual;
- public function SaveToString ( ) : string ; virtual;
- public procedure SaveToFile ( const AFileName : string ) ; virtual;
- public procedure SaveToStream ( const AStream : TStream ) ; virtual;
- public procedure AddUnitEntity ( const AUnit : TGorillaScriptCustomUnitEntity ) ;
- public function GetUnitEntity ( const AName : string ) : TGorillaScriptCustomUnitEntity ;
- public function ToJSON ( ) : string ;