I have an array that represents some mapping between strings. The key and the value both have (business) meaning. For example, in the array:
[
'10000' => 'f4970340-9cb7-4380-948c-54e0d1556d58',
'20000' => '665cdd7d-dbef-4c0a-963e-467a68fa097f',
'84000' => '5b7f0abc-a515-4409-8b70-f1aafeef5038',
… # more entries
]
10000, 20000 and 84000 represent customers. The UUIDs represent groups to which the customers belong.
Is there any convention / best-practice of how to document the meaning of the strings? I am not talking about documenting the types (=strings).
Something like:
/**
* @return string[]
* [
* customerId => groupId,
* …
* ]
*/
public function getCustomerIdGroupIdMap(): array
{}