Adam’s July 2022 Meeting Summary
- Lets do some pascal scripting, as used in our ETL (Exchange, Transform, Load) tool – Lorenz Wolf
- A quick look at Lazarus – Ian Hamilton
- Introduction to Network Boundary Security – Rob Lambden
Jason chaired the meeting on Zoom as usual and started with good introductory chats, Q&A and some (not so good) problem-solving. Kevin Bond is on his way to Australia, where he will attend the Ozzie Dev Group meeting in Sydney, we asked him to report back.
A quick look at Lazarus – Ian Hamilton
Most members are familiar with Lazarus as an “open source Delphi”, the “FPC” refers to the Free Pascal Compiler which the IDE calls to actually build source code into executables. Lazarus (“Laz”) is very Delphi-like, having a RAD approach, mimicking Delphi’s DFM/PAS mechanism for visual UI / source code segregation, and with other direct parallels in source-code organisation (using LPK files for Delphi’s DPKs, and PPUs for Delphi’s DCUs). Ian pointed out that it has existed for around 30 years (!) so is not some recent start up or flash in the pan.
Lazarus’s open source license is simple: If you change Lazarus source code you feed your changes / improvements back. You own and can do what you like with your own source code.
Once you have written a project on any platform it should compile to any other platform (Apple, Android and literally dozens of others) provided you follow rules which are slightly different from Delphi, but the cross compilation process is not particularly straightforward, there is no equivalent of the FMX/VCL divide as in Delphi.
There are hundreds of third party component-sets for Lazarus, most are free/open source. Ian has installed the TMS components for Lazarus, I didn’t ask, but I assume those are commercial.
Out of the box Lazarus comes with a really good selection of enterprise quality data-components, linking to SQLServer, Oracle, PostGres, Firebird, Interbase, MySQL, ODBC and possibly a couple of others I missed. The mechanisms for data-connectivity are similar to old-school Delphi, with Datasources and Datasets, there are no LiveBindings.
Some of Delphi’s open source components (SynEdit for example) are directly cross-compatible and install into Lazarus.
The UI of the IDE seemed decent, a bit old-school, but more than functional, and much, much better than the version of Laz I worked with around 2005, when there was hardly even a functional form-designer.
The only big difference source-code difference with Delphi Ian reported was that it uses a HH file as a header for the declaration of the interface of an object, with the PAS file for the implementation. This has been done to ease writing cross-platform applications, as where implementation needs to differ by O.S., different PAS files can be used per platform (if I understood correctly).
Ian has noticed some areas where Laz under-performs: Multi-threading for example. Much new Delphi source (objects like TTask) are just missing from Laz. I think he said that language support in Laz is almost identical to Delphi (ie things like Attributes, Generics etc. are all supported) but I may have mis-understood this.
It was a strong session, and definitely tweaked a few member’s interest in Lazarus. It is clear that good sized projects can be built in it.
I have added some screen shots of Ian’s talk to this post.
Lets do some pascal scripting, as used in our ETL (Exchange, Transform, Load) tool – Lorenz Wolf
Lorenz partly gave a case-study of his business’s main commercial application, zooming in from this to show how they use the FastScript scripting components within the app.
FastScript is a powerful set of components from the excellent software house which produces other “Fast” products (FastReports and FastCube being two I know of).
FastScript allows an App to surface a scripting window into which the user can type code which references objects, methods and properties of the main App (if they are made available to the FastScript object).
There are fairly simple calls, which are roughly in the format:
ScriptObject1.AddMethod(‘Method name’, MyMethod);
Once the App is run and the Script Object instantiated, “MyMethod” can be called and the code in the compiled App with the associated method name will run, with parameters passed from the ScriptObject.
Lorenz showed really good examples of using scripting in his app to run complex back-office functionality manipulating application-generated data and using it to create XML files which could be posted to web-hosts to generate digital paperwork.
The FastScript component can also register external DLLs, and the function-calls surfaced in them, allowing a further layer of inter-operability. FastScript is a commerical library, it is not super-expensive.
Introduction to Network Boundary Security – Rob Lambden
I am going to come straight out and say that I am a coder first and not much of a network-geek, so much of Rob’s excellent seeming talk went straight over my head. I will make my best effort at expressing what he discussed. Rob’s business actually manages a bit of the internet, which means helping the actual packets of data rush around that giant global whirlpool based on IP4 and IP6 addresses, and their subnet masks, under constant threat of hacking or being lost on their way.
Rob patrols his boundaries with IPTables, NETFilter and IPSet, mostly in kernel-space, using Linux which he says is vastly superior to Windows as an operating system in this context. He makes his best efforts to identify and exclude large numbers of hackers, phishers and other bad-actors, but if you want to know more about this you will have to ask him yourself, as it was mostly Greek to me.
This session was a taster (Powerpoint only) for a longer code-based session next month.
There is no meeting in August, so we will see members old and new in September. A good deal of chat was posted on the Slack, so please refer there for extras, web-links to Lazarus/FPC etc.