Embarcadero FireDAC – Great Video

Embarcadero are pretty good about training webinars. These are a great way to get more out of their products. Invariably the live seminars appear on youtube after the event (although watching them on youtube means you don’t get the chance to ask questions in the live Q & A sessions at the end of the webinar).

 Here’s a link to one such particularly good webinar recording on using FireDAC, presented by Cary Jenson. Take a look !

FireDAC in Depth – by Cary Jenson

Naming Advice – A Rule

Consider this:

If you have to write a comment in your code is it because you haven’t named your variables or functions well? I very very many cases the answer is yes.

Here’s a simple example

Consider the case of a control system for a passenger lift in a tower block. You have some digital inputs in a class called DigitalInputs and this has a series of functions to get the values of the inputs wired to input pins on your hardware. Lets suppose your software wants to check if the doors of the lift are safely closed (if they are the software may then start to move the lift to a different floor).

If the door is closed limit switch is wired to pin 16 for example your code might be:

if (DigitalInputs.Pin16IsActive()) {
// … your code to start the lift moving goes here
}

At a later date you may think this is not particularly well written so you choose to add a comment:

if (DigitalInputs.Pin16IsActive()) /* check the door is closed */ {
// … your code to start the lift moving goes here
}

This is clearer than the first sample. But a much better improvement is not to add the comment but instead to rename the member function Pin16IsActive() in class DigitalInputs to a better name, for example LiftCabDoorIsClosed(). The code then becomes much more readable (without comments)

if (DigitalInputs.LiftCabDoorIsClosed()) {
// … your code to start the lift moving goes here
}

The big bonus is that now, everywhere this function is called throughout the code, it is clear what is being checked.

Naming rule: If you have to write a comment in your code think to yourself “is it because a variable or function is badly named?”

Embarcadero Road Map for 2017/2018

Embarcadero have just updated their published road map

As usual C++ development follows hot on the heels of the latest Delphi enhancements and, as usual, you feel “as soon as we have that, it will be really good product” !

There are lots of exciting things to come, take a look:

https://community.embarcadero.com/article/news/16519-rad-studio-roadmap-may-2018

Embarcadero In London

PawelGlowackiInLondonJust back from the Embarcadero presentation in London, at which the principal speaker was Pawel Glowacki. The photograph shows Pawel in a characteristically friendly mood and also the venue’s bar menu! A very interesting day highlighting recent innovations in the latest Tokyo 10.2 release of RAD studio.

Small but significant improvements in the IDE (including the first tastings of “Quick Edit” of component properties (currently just VCL but FireMonkey promised for the future) were followed by an introduction complete with demonstration to AppTethering. This powerful (yet easy to implement and use) technology is also available with the new Linux Delphi compiler which was also covered in some depth.

The presentation also included the FireMonkey for Linux desktop third party application that has been developed by one of the key designers behind the original FireMonkey development. I was not the only one in the audience who was curious as to why this branch in the “Embarcadero RAD studio does everything” tree was being developed by a third party company.

The fairly intensive morning was concluded with an introduction to the power of RAD Server (previously known as Enterprise Mobility Services) including an example showing how it can be used to run specifically developed RAD server *.bpl packages.

Stephen Ball was also on hand to provide up to date information on the latest version of InterBase (InterBase 2017).

The drive behind the day was provided by the UK Embarcadero software reseller, GreyMatter. It is great to meet other enthusiastic Delphi and C++ developers and to pick up tips and development methodology from Embarcadero experts.

The First Thought Counts !

What is the difference between a good software engineer and a weaker software engineer?

Answer: When you give a weak software engineer a new job the first question they ask themselves is “how am I going to design this?” where as the good software engineer asks themselves “how am I going to test the code?”

Be aware that “job” could mean developing a new class to represent a simple concept or it could mean developing a complete database management system for a large corporation.

Embarcadero C++ Tokyo

A new version of Embarcadero’s flag ship product, RAD Studio is soon coming out. It will be called Tokyo and as usual can be purchased complete, just Delphi or just C++. One of the key Embarcadero staff, Pawel Glowacki, is on the road now publicising the new features, including the support for Linux servers. Pawel’s presentation in Prague

I will have more to say about this release when it becomes available to the public, so watch this space.