Top Method Summary
Options Name Purpose
LOGICAL EndsWithTilde (character) Returns if the text ends with a tilde (line continuation)
CHARACTER GetDefinitionValue (character, character) Returns the value of a preprocessor definition when the source code line defines the preprocessor name
CHARACTER GetPreprocessorDefinition (character, longchar) Searches the source code for a preprocessor definition
LOGICAL IsWhiteSpace (character, integer) Returns if the character at the given position is a blank or a tab

Top Constructor Summary
Options Name Purpose
SourceCodeHelper () Protected default constructor


Method Detail
Top

LOGICAL EndsWithTilde (character)

Purpose: Returns if the text ends with a tilde (line continuation)
Notes: SCL-5965

Parameters:
pcText CHARACTER
The (trimmed) source code line
Returns LOGICAL
Logical value indicating if the text ends with a tilde
Top

CHARACTER GetDefinitionValue (character, character)

Purpose: Returns the value of a preprocessor definition when the source
code line defines the preprocessor name
Notes: SCL-5965. Recognizes &SCOPED-DEFINE and &GLOBAL-DEFINE (not
abbreviated, case-insensitive) followed by blanks or tabs and the
name. The value is the remainder of the line after the single
blank or tab that follows the name - further leading white space
remains part of the value, as in earlier releases

Parameters:
pcLine CHARACTER
The trimmed source code line
pcPreprocessorName CHARACTER
The preprocessor variable to search for
Returns CHARACTER
The value (without continuation lines), an empty string when the definition has no value, ? when the line does not define the preprocessor name
Top

CHARACTER GetPreprocessorDefinition (character, longchar)

Purpose: Searches the source code for a preprocessor definition
Notes: Returns the first definition of the name. Recognizes
&SCOPED-DEFINE and &GLOBAL-DEFINE (not abbreviated,
case-insensitive) at the beginning of a line, separated from
the name by blanks or tabs. The value is the remainder of the
line after the single blank or tab that follows the name; a
definition without a value returns an empty string. A line that
ends with a tilde continues on the next line: the tildes are
removed and the trimmed next line is appended. The continuation
ends at an empty line or at the end of the source code

Parameters:
pcPreprocessorName CHARACTER
The preprocessor variable to search for
plcSourceCode LONGCHAR
The whole source code
Returns CHARACTER
The value of the preprocessor name, ? when the name is not defined
Top

LOGICAL IsWhiteSpace (character, integer)

Purpose: Returns if the character at the given position is a blank or a tab
Notes: SCL-5965

Parameters:
pcText CHARACTER
The text to test
piPosition INTEGER
The position of the character to test
Returns LOGICAL
Logical value indicating if the character is a blank or a tab


Constructor Detail
Top

SourceCodeHelper ()

Purpose: Protected default constructor
Notes: Disallow instance creation



©2006-2026 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       10.10.2026 15:35:54