GitHub Package
the javascript


Contents 00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43    101 102 103 201 202 203 204 301 302 303 304 401 402 403 404 501 502 503 504 601 602 603 604    700 701 702 703 704 705 706 707 708 709 710 © 2024 Steen Hansen
00 - Readme Example

In this example, the checking function PRE_check_aLottery(), which is executed before the production function aLottery() is activated via
type_czech = TypeCzech('LOG-ERRORS')
  - OR -
type_czech = TypeCzech('THROW-EXCEPTIONS')
TypeCzech monitoring is turned off via
type_czech = TypeCzech('NO-CHECKING')
  - OR -
type_czech = TypeCzech()
When TypeCzech is turned on, PRE_check_aLottery() ensures that aLottery()'s parameters are a string, an array of numbers, and a date with the checkParam_type() call.

PRE_check_aLottery() also gives warning when parameters are empty with the checkParam_empty() call. This means that an error occurs when the lottery_name is an empty string, and/or if there are no numbers in the lucky_numbers array.

Console Output