My approach. The core is the engine. - page 15

 
Реter Konow:

You'll see, an array of prototypes is created once. And then, it is VERY rarely changed. Only in case of serious modifications in the program.

And what if you want to do it dynamically?!

 
Dmitry Fedoseev:

How can these two provisions coexist together: the lack of convenience for the programmer and the rapid development of the program? How can you develop a program quickly if it is inconvenient to do so?

It is all about proportions. The inconvenience of making an array of prototypes is obvious. The convenience of direct access to the kernel from anywhere in the program, the use of element focus and other things is HUGE.

In short, there is far more convenience in my approach than inconvenience. But, for that, you have to learn to own it.

 
Vitalii Ananev:

And how will you do if it is necessary to make not a rectangular button, but for example a round or triangular one?

If you use OOP, you have to create a base class Button, which has an abstract Draf method, responsible for drawing buttons. For a round button, you will need to create an heir of Button, which will suffice to override the Draf method, which will implement drawing of the round button. For a rectangular button, it will also suffice to create an heir of Button and override the Draf method to draw a rectangular button.

How would it all look if you use your method?

In my case, it's MUCH simpler.

1. I add a flag property to the list of object properties.

2. I increase the length of the Kernel row by 1 cell, which will be reserved for the new property.

3. I create a keyword that sets a flag in the circle property of the button.

4. I add a circle drawing mechanism to the Drawing block, which will be entered after checking the circle flag of the button in the Kernel.

 
Реter Konow:

It's all about proportions. The inconvenience of putting together a prototype array is obvious. The convenience of direct access to the kernel from anywhere in the program, using element focus and other things is MUCH more.

In short, there is far more convenience in my approach than inconvenience. But, you have to learn to own it to do so.

You're badly mistaken about the convenience of accessing a global array. It's one now, or several. And if there are several subsystems written in this style in a program, it will be a mess, chaos and confusion.

 
Dmitry Fedoseev:

You're very much mistaken about the convenience of accessing a global array. It's one now, or several. And if there are several subsystems written in this style in the program, it will be a mess, chaos and confusion.

There are several Cores in the program, which are only used during the Main Cores construction phase. Only the Main Kernel, and the Parameter Kernel (the property kernel of control parameters) are globally accessible.

Everything is quite handy. I have no complaints.

 
Реter Konow:

There are several Kernels in the program, which are only used during the Main Kernel construction phase. Only the Main Core, and the Parameter Core are globally accessible.

Everything is quite handy. I am not complaining.

And how many customers do you have and how quickly do you make their revisions? Have you ever worked with other people's programs written in this style?

 
Реter Konow:

In my case, it's MUCH simpler.

1. I add a flag property to the list of object properties.

2. I increase the length of the Kernel row by 1 single cell, which will be reserved for the new property.

3. I create a keyword that sets a flag in the circle property of the button.

4. I add a circle drawing mechanism to the Draw block which will be entered after checking the button's circle flag in the Kernel.

When you start actually doing this, you then get confused with all your supposedly "objects".

And it doesn't get any easier. In your case (as you wrote yourself) you have to do 4 steps. In my example using SRF, there is only one action.

upd.

At the same time, you also need to control some flag, so as not to confuse whether your button is round or square.

 
Dmitry Fedoseev:

How many customers do you have and how quickly do you complete their revisions?

At the moment, I have one customer. I complete their tasks very quickly. 3-4 hours and a new, fully functional window is ready. Together with the connection interface. I also quickly fix bugs in the engine and send him new versions. 9 windows in a few days + engine changes, bug fixes, adding features... All very fast.

 
Реter Konow:

Everything is quite comfortable. I'm not complaining.

Well, you understand that you alone are not enough. The massiveness of your engine will depend on whether other programmers like it (you alone are not enough for all customers). And if the progerms don't like it, then... alas and ah, the fate of your creation will be glorious.

 
Vitalii Ananev:

When you start really doing this, you then get confused by all your alleged "objects".

And it doesn't get any easier. In your case (as you wrote yourself), you have to do 4 actions. In my example using RPF, there is only one action.

upd.

At the same time you also have to control some flag, so as not to confuse what your button is round or square.

I've actually been doing this for over a year now. And I don't get confused)).

Reason: