Wrong forum, but ...
It refers to the ids in the mdl_context table.
There, clear as mud
OK, so what a context is is explained here: http://docs.moodle.org/en/Question_permissions_explained_with_diagrams
How that is stored in the database is sort of explained here: http://docs.moodle.org/en/Development:Database_schema_introduction#The_roles_and_capabilites_system. Actually, the best docs is probably in lib/accesslib.php. For example, look at the PHPdoc comment for get_context_instance.
It refers to the ids in the mdl_context table.
There, clear as mud
OK, so what a context is is explained here: http://docs.moodle.org/en/Question_permissions_explained_with_diagrams
How that is stored in the database is sort of explained here: http://docs.moodle.org/en/Development:Database_schema_introduction#The_roles_and_capabilites_system. Actually, the best docs is probably in lib/accesslib.php. For example, look at the PHPdoc comment for get_context_instance.