in clearcase-server/src/jetbrains/buildServer/buildTriggers/vcs/clearcase/ClearCaseValidation.java [229:260]
public boolean validate(Map<String, String> properties, Collection<InvalidProperty> validationResultBuffer) {
final String ccViewRootPath = trim(properties.get(Constants.CC_VIEW_PATH));
//check path exists
if (isEmpty(ccViewRootPath)) {
validationResultBuffer.add(new InvalidProperty(Constants.CC_VIEW_PATH, Messages.getString("ClearCaseValidation.clearcase_view_root_path_missed"))); //$NON-NLS-1$
debug(String.format(SINGLE_PARAM_VALIDATION_FAILED, ccViewRootPath));
return false;
}
assert ccViewRootPath != null;
if (ReferencesResolverUtil.containsReference(ccViewRootPath)) return true;
//check paths is well formed
try {
CCPathElement.normalizePath(ccViewRootPath);
} catch (VcsException e) {
if (!mayContainReference(ccViewRootPath)) {
validationResultBuffer.add(new InvalidProperty(Constants.CC_VIEW_PATH, e.getMessage()));
debug(String.format(SINGLE_PARAM_VALIDATION_FAILED, ccViewRootPath));
return false;
}
}
//check path is directory?
final int countBefore = validationResultBuffer.size();
checkDirectoryProperty(Constants.CC_VIEW_PATH, ccViewRootPath, validationResultBuffer);
if (countBefore != validationResultBuffer.size()) {
debug(String.format(SINGLE_PARAM_VALIDATION_FAILED, ccViewRootPath));
return false;
}
debug(String.format(SINGLE_PARAM_VALIDATION_PASSED, ccViewRootPath));
return true;
}