getDeploymentBasePath method
The base path for storing all deployment related files on the form
<localApplicationPath>/carp/deployments/<study_deployment_id>
Implementation
Future<String> getDeploymentBasePath(String studyDeploymentId) async {
if (_deploymentBasePaths[studyDeploymentId] == null) {
final path = await carpBasePath;
final directory =
await Directory('$path/$CARP_DEPLOYMENT_FILE_PATH/$studyDeploymentId')
.create(recursive: true);
await Directory(
'$path/$CARP_DEPLOYMENT_FILE_PATH/$studyDeploymentId/$CARP_CACHE_FILE_PATH')
.create(recursive: true);
await Directory(
'$path/$CARP_DEPLOYMENT_FILE_PATH/$studyDeploymentId/$CARP_DATA_FILE_PATH')
.create(recursive: true);
_deploymentBasePaths[studyDeploymentId] = directory.path;
}
return _deploymentBasePaths[studyDeploymentId]!;
}