I'm trying to use a constant in a PHP Namespace Use statement:
define('API_VERSION', 'v201705');
I'd like to be able to use the constant above in the use statement below
use api\v201705\service;
I don't know if this is possible as the following obviously does't work:
use api\.API_VERSION.\service;
Can anyone suggest a different approach to using a constant in this scenario?
Any help would be appreciated.
Thanks