Welcome to the new DelphiDabbler Code Library Documentation.

This is a new site that's currently running on alpha code. There are going to be bugs. If you discover any, please report them on the site's issues page (GitHub account required). Thanks.

Warning: Many URLs are going to change. Refer to the README file to discover which library project's documentation has been completed.

Constants

Project: Console Application Runner Classes

Unit: PJConsoleApp

Applies to: ~>3.0

The following constants are declared in the library.

cOneSecInMS

const cOneSecInMS = 1000;

Number of milliseconds in a second. This can be a useful value when setting properties such as TPJCustomConsoleApp.MaxExecTime and TPJCustomConsoleApp.TimeSlice.

cOneMinInMS

const cOneMinInMS = 60 * cOneSecInMS;

Number of milliseconds in a minute. This can be useful when setting the TPJCustomConsoleApp.MaxExecTime property.

cDefTimeSlice

Introduced: v1.0

cDefTimeSlice = 50;

Default value of the TPJCustomConsoleApp.TimeSlice property.

There should rarely be a need to use this value directly.

cDefMaxExecTime

const cDefMaxExecTime = cOneMinInMS;

Default value of the TPJCustomConsoleApp.MaxExecTime property.

There should rarely be a need to use this value directly.

cAppErrorMask

const cAppErrorMask = 1 shl 29;

Mask that is ORd with application error codes. This sets bit 29 in accordance with Windows requirements. Application error codes are tested for by ANDing them with this constant.

The IsApplicationError routine is provided to perform this test so there should be no need to use cAppErrorMask directly.

cAppErrorTimeOut

const cAppErrorTimeOut = 1 or cAppErrorMask;

Error code used to report that an application has timed out. c.f. the TPJCustomConsoleApp.ErrorCode property.

cAppErrorTerminated

const cAppErrorTerminated = 2 or cAppErrorMask;

Error code used to report that an application has been terminated. c.f. the TPJCustomConsoleApp.ErrorCode property and TPJCustomConsoleApp.Terminate method.