PHP function - get_defined_constants() gives all the constants defined in current scope. It can be CORE Constants, extensions defined constants and user defined constants. As a developer you may be interested in all defined constants or user defined constants at a time. As the total number of constants printed on screen can be very high, you may like to print the concerned constants at a time.
For user defined constants:
<?php $const = get_defined_constants(true); print_r($const['user']); ?>
For Core Constant, user 'Core' as keyword -
For checking all values in the function, just print it as see what is stored within it.