SAP CL_ABAP_RANDOM OO Class - Pseudo Random Number Generator
CL_ABAP_RANDOM is a standard SAP object class available within R/3 SAP systems depending on your version and release level. You can view/maintain the class details by entering its name into the relevant SAP transactions such as SE24, SE80 or even SE84. Below is the documentation available for class CL_ABAP_RANDOM including details of:
- Interface class implementations
- Inheritance details
- Methods defined within class ( including link to full details )
- Attributes ( including initial values )
- Class Events
Interface Implementation
This OO class is an Interface Implementation, which means it will implement its own version of the methods from implementation class IF_SERIALIZABLE_OBJECTMethod list of CL_ABAP_RANDOM SAP class
A method is a coding block that performs a certain procedure (i.e. ABAP functionality) on an object within the overall SAP class. In simple terms if the object is an SAP database table a method could be the procedure to add a record or to delete a record. If you are new to OO in many respects, the implementation of a method is similar to a function module and can be called in a very similar way using CALL METHOD.
Instead of "CALL FUNCTION", Methods are referenced using the following syntax: CALL METHOD =>methodname EXPORTING/IMPORTING...
| Method Name | Description | Visability |
| CREATE | Factory | Public |
| CALL METHOD cl_abap_random=>CREATE...more details | ||
| CREATE_TESTER | Factory for Standard Test PRNG | Private |
| CALL METHOD cl_abap_random=>CREATE_TESTER...more details | ||
| DECFLOAT16 | Compute a packed RN of type decfloat16 | Public |
| CALL METHOD cl_abap_random=>DECFLOAT16...more details | ||
| DECFLOAT34 | Compute a packed RN of type decfloat34 | Public |
| CALL METHOD cl_abap_random=>DECFLOAT34...more details | ||
| FLOAT | Compute a Floating Point RN in [0,1) | Public |
| CALL METHOD cl_abap_random=>FLOAT...more details | ||
| INITPRNG | Initialise a PRNG (Compute State Array) | Private |
| CALL METHOD cl_abap_random=>INITPRNG...more details | ||
|
| ||
| INT | Compute a Signed Integer RN | Public |
| CALL METHOD cl_abap_random=>INT...more details | ||
| INT31 | Compute a 31 Bit Integer RN (i.e. 0 <= Value <= 0x7FFFFFFF) | Public |
| CALL METHOD cl_abap_random=>INT31...more details | ||
| INT8 | Private | |
| CALL METHOD cl_abap_random=>INT8...more details | ||
| INT8INRANGE | Compute a 64-Bit Integer RN in [a,b] | Public |
| CALL METHOD cl_abap_random=>INT8INRANGE...more details | ||
| INTINRANGE | Compute a Random Integer RN in [a,b] | Public |
| CALL METHOD cl_abap_random=>INTINRANGE...more details | ||
| PACKED | Compute a Packed RN (31 Digits, No Decimals) | Public |
| CALL METHOD cl_abap_random=>PACKED...more details | ||
| PACKEDINRANGE | Compute a Packed RN in [a,b] (31 Digits, No Decimals) | Public |
| CALL METHOD cl_abap_random=>PACKEDINRANGE...more details | ||
| SEED | Compute a Random Seed (Integer) | Public |
| CALL METHOD cl_abap_random=>SEED...more details | ||
| TESTINIT | Special Initialization for Standard Test | Protected |
| CALL METHOD cl_abap_random=>TESTINIT...more details | ||
CL_ABAP_RANDOM attributes
List of attributes within class CL_ABAP_CHAR_UTILITIES. These can be referenced using the following syntax CL_ABAP_CHAR_UTILITIES=>. Although depending on where you are inserting the ABAP code you do need to check if the attribute is public or private.
| Name | Level | Description | Initial Value | Type | Visability |
| FALSE | Constant | FALSE | SPACE | LIKE ABAP_BOOL | Private |
| INITF | Instance Attribute | Flag: State Computed | LIKE I | Protected | |
| LEFT | Instance Attribute | Number of Left States | 1 | LIKE I | Protected |
| NEXT | Instance Attribute | Kernel: Pointer to Next State | LIKE %_C_POINTER | Protected | |
| STATE | Instance Attribute | PRNG State Array | LIKE ABAP_PRNG_STATE | Protected | |
| TRUE | Constant | TRUE | 'X' | LIKE ABAP_BOOL | Private |
CL_ABAP_RANDOM types
ABAP_PRNG_STATE -P31_0 -
Links to Related Class(s)
CL_ABAP_...Full list of available SAP object classes
Search for further information about these or an SAP related objects