Advanced User Guide

Help Version: 3.11 - 21/DEC/2016

Note - Read Carefully

What follows describe how Builder's Heaven - Codes Everything You Code! works and has been thought; this means that the content must be considered as an intellectual property of the author. You receive here informations with the purpose to better configure the Builder's Heaven M.P.S.C. , in order to obtain best customized results. You are authorized to use all these informations, but you must not use informations to create applications similar or equal to Builder's Heaven. Otherwise you are prayed to not use the following advanced guide and its contents.

Introduction for Advanced BH Users

This Section has been written for those that want to comprehend how Builder's Heaven works and obtain the best results during the programs generating process. This means that you should know enough the base options before introduce yourself to advanced programming of the software.

Creating new M.P.S.C. is the Key to obtain the maximum from a source code generator like Builder's Heaven.

To create a standard M.P.S.C. go to Advanced Options and Language Definition and use the "CREATE DEFAULT" button. Otherwise copy an original M.P.S.C. and use it as example.

Main Pseudo Source Code (Internal Structure)

Main Pseudo Source Code Schema and Structure

The M.P.S.C. is a TEXT FILE in ASCII format that contains all the code that will be selected (using the left flags - 1 to 6) and normalized (using the Key To Value conversions). You can edit this file from the interface, inside the advanced options but you can also use the pre-build versions that come with the software. I suggest you to ALWAYS create a Backup version if you modify the M.P.S.C. in the first times.

M.P.S.C. can contains every type of code: from Cobol to C++, from Easytrieve to procedural emails, from Rexx to Html, or Javascript or "Everything you Code!". These are just examples in order to take you to the correct line of view: the M.P.S.C. can holds whatever you need for generating and reuse that code. Remember at last that if you insert "code" inside the Builder's Heaven using M.P.S.C. and other technologies, you can save your knowledge during years!

How to Edit and What to Edit

Note: in [square brackets] the references to the image above.

  • client=3.00 : [A] This is the Client required to use this Pseudo-Code.
  • heavmem=3.00 : [A] This is the current version of the Pseudo Code below. You should trace every changes updating the version.
  • numlines=3339 : [A] This is just an information that allow the progress bar of the Generate Program Panel to follow the progress of the elaboration.
  • [THE CODE BEGINS HERE] : [A] Your Pseudo-code starts below this TAG.Warning, if missed the program cannot be build.
  • FLAG 1 - 6 : [C] Every row you add to the Custom Code start from the 7th byte, because the first 6 are occupied from Flags information. Flags identify the row on the right and the rules of insertion into the final code. Refer to FLAGS guide for more details.
  • [COBOL CUSTOM ... ] : [B] Assuming COBOL as example, inside the M.P.S.C. you will notice those tags inserted into 2 squares parenthesis. Refer to CUSTOM CODE guide for details
  • <BH_CURR_DATE>; <BH_PROG_NAME>; etc : [D] These are System Key To Value, autocompleted by the generating process with corresponding setup values.
  • //-<NEWFILEOUT> : [E] These lines are for FileCutter module, an additional process that cut your final source into many files, as many as those lines are.
  • The Code : All the rest of the data is code, your Code! Every line you add will appears in the respective position accordingly with enabled and disabled Flags. The prototype is: "What you See is What you Get". So you should implement a base structure of your source and then proceed with optional code. For example, if you plan a C++/Java/C# template, you should design all class elements; if you plan an Html template, you should design "<head>" and "<body>"; and so on with all base structure of the various programs. The creation and configuration of this code lines are an hard task of programming,and is up to you; but when you have prepared a good M.P.S.C. , you will obtain a good final and modular code... Forever! That's why Builder's Heaven has been created...

Flags - from 1st to 6th

Builder's Heaven get the destination code from the M.P.S.C. ; inside this file there are , in the left side, 6 "FLAGS" (so they are called) with the size of 1 char each. They identify the type of code there is on the right, and if that line is useful for to us, analyzing the input request from the interface. You can easily modify the M.P.S.C. following the rules that follow.

These Flags are in order of importance, from the left to the right . In order to create the final code you have requested, the Builder's Heaven elaborate every line of the M.P.S.C. and decide if it's in your choices or not.

(note : if you change something inside the M.P.S.C. , I suggest to heavy test these changes Also remember to create a Backup copy of the M.P.S.C. ).

To open M.P.S.C. you can execute Builder's Heaven, enter Program Base Parameters and click the M.P.S.C. Button.

FLAGS :

  • Flag 1 - It's the most important flag; it's defined in the Advanced Options and Language Definition panel as Flag1 and it's always the same for a language.
  • Flag 2 - There some system Flag2: B for batch, R for routines and M for Match, as defaults. Moreover the configuration of Files uses F, and DB Accesses uses 2. The remaining flags can be redefined for personal customizations in the Custom Flags Panel.
  • Flag 3 - There some system Flag3: they customize better the options in Flag2 in File Definitions or in DB accesses. The remaining flags can be redefined for personal customizations in the Custom Flags Panel.
  • Flag 4 - There some system Flag4: it normally defines that the following code is a "comment". It becomes extremely important during the DB lines, where it creates the lines that will be identified as columns, and so on. The remaining flags can be redefined for personal customizations in the Flags 4 Panel.
  • Flag 5 - There some system Flag5: The code that use the fifth FLAG is very limited, but not less important. Inside the DB this flag identify for example if you have a first prototype of your line or if the line can be duplicated for each field or identify if the column require the Null value or not. There is no user implementation about Flag5 allowed.
  • Flag 6 - not implemented.

System Flags Table

This list of flags are predefined in every language you create, and they are not available if you plan to create new Flags. System flags activate themselves automatically, using the software interface. The user should not implement them manually inside Custom Flags and Flags 4 pages, in order to avoid generating issues. If a flag can be customized, it is exposed inside the Advanced Options and Language Definition.

Legend:

Predefined Flag 2
F1 F2 F3 F4 F5 F6 Description
(1) B Flag 2th - Batch Mode selected (*can be reconfigured)
(1) R Flag 2th - Routine Mode selected (*can be reconfigured)
(1) M Flag 2th - Match Mode selected (*can be reconfigured)
(1) 2 Used from all DB accesses (if activated)
(1) F Used from all I/O accesses
Predefined Flag 3
(1) F I File Input reference (ref. File I/O Accesses)
(1) F O File Output reference (ref. File I/O Accesses)
(1) F C File Output flagged as Excel reference (ref. File I/O Accesses)
(1) F R Report File Output reference (ref. File I/O Accesses)
(1) F D Program Description (Multiline) (ref. Base Parameters)
(1) 2 S Select for DB accesses (ref. DB Details)
(1) 2 F Fetch for DB accesses (ref. DB Details)
(1) 2 I Insert for DB accesses (ref. DB Details)
(1) 2 U Update for DB accesses (ref. DB Details)
(1) 2 D Delete for DB accesses (ref. DB Details)
(1) 2 R Rollback code for DB accesses (ref. Base Parameters)
(1) 2 C Commit code for DB accesses (ref. Base Parameters)
Predefined Flag 4
(1) 2 (~) X EXTRACTED Columns code for DB accesses (ref. DB Details)
(1) 2 (~) W WHERE Columns code for DB accesses (ref. DB Details)
(1) 2 (~) N NULL Columns code for DB accesses. Appears if null field is found. (ref. DB Details)
Predefined Flag 5
(1) 2 (~) (~) 1 First Rows of Columns code for DB accesses (ref. DB Details)
(1) 2 (~) (~) A Repeated Rows (from 2th to nth) of Columns code for DB accesses (ref. DB Details)
(1) 2 (~) (~) N Null management of Columns code for DB accesses (ref. DB Details)
(1) (~) (~) (~) P Identify a called Procedure for Sequencer Module (ref. Sequencer)
(1) (~) (~) (~) S Identify a Sequencer Row for Sequencer Module (ref. Sequencer)

Builder's Heaven System Key To Value

System Key To Value are a series of KEYS that became VALUES due to the user input inside the Program Characteristic phase; they will return to you the right converted code. There are User Key to Value and System pre-build ones. Here a list of the most common.

Examples below assume "#" as the Iterable Wildcard from the setup of language.

Builder's Heaven System Keys To Value
Key Value Description
<BH_FTP_USER>

User TSO edited from FTP Panel

<BH_PROG_NAME>

Program Name

<BH_CURR_DATE>

Current Date of the day you created the program

<BH_PROGRAM_DESCRIPTION#>

Recursive - becomes the program description

<BH_MPSC_VER>

Version of the M.P.S.C. ; at the top of this file there is a TAG : "heavmem=..." . You should change this value in order to trace the differences between the changes, inside you final programs.

<BH_COMPANY>

Company's Name

<BH_NAME_SURNAME>

Programmer Name and Surname ,edited into the FTP and User Panel

<SEL/FET/DEL/INS/UPD/ROL/COM>

Results of your DB Selections

<' '>

This is managed where there are DB columns; it changes into ZEROES and SPACES due to the column Type (Numeric or Alphanumeric).

<+>

Used inside the Easytrieve into the DB accesses. It's replaced by "+" normally, but if B.H. is elaborating the last column selected , it changes to spaces. Resolve the DB continuity of Easytrieve declarations.

<N+>

Recursive inside DB Flags: it's converted into a "+" if necessary and if the current variable can assume a NULL value.

<NV>

Recursive inside DB Flags: it's converted into "," if necessary and if the current variable can assume a NULL value.

UIN#/FILEIN#

Replaced by the corresponding Input File

UOUT# / FILEOUT#

Replaced by the corresponding Output File

DESC-I# / DESC-O# / DESC-R#

Replaced by the corresponding Short file and report descriptions

T-#F / T-#S / T-#U / T-#I / T-#D

Replaced by the corresponding Db access schema

TABEL-#F / TABEL-#S / ...

Replaced by the corresponding DB Table

INCLU-#F / INCLU-#S

Replaced by the corresponding DB Include

LEV01-#F / LEV01-#S / ...

Replaced by the corresponding 01 variables level of the DCLGEN

DESCDB2-#F / DESCDB2-#S

Replaced by the corresponding DB Short Descriptions

<FIELD> or <DBFIELD>

Recursive inside DB Flags: it's converted into the DB variable or the DB Column currently processed (Ex. NAME). Refer to the "LanguageConfiguration" file where they are defined.

<DBTYPE>

Recursive inside DB Flags: it's converted into the DB Type indentified (Ex. TEXT). Refer to the "LanguageConfiguration" file where they are defined.

<DB2_VAL>

Recursive inside DB Flags: it's converted into the DB Value currently processed ( Ex: (15,2) ) .

<COBOL_VAL>

Recursive inside DB Flags: it's converted into the Cobol Value currently processed ( Ex: S9(13)V9(2) COMP-3. ).

<SEQUENCER-...>

Constant part of the Sequencer Tags to define Sequencer Points . Complete the TAG as you prefer (es: )

<2APX> / <APX>

Manages the apix, double apix or zero in relaction with the DB variable its working on.