#include <ModelAPI_AttributeRefAttr.h>
bool SketchPlugin_ExternalValidator::isValid(const AttributePtr& theAttribute,
- const std::list<std::string>& theArguments) const
+ const std::list<std::string>& theArguments,
+ std::string& theError) const
{
if (theArguments.size() != 1)
return true;
bool isParameterExternal = isExternalAttribute(aFeature->attribute(aFrontArgument));
// it is not possible that both features, attribute and attribute in parameter, are external
- if (isAttributeExternal && isParameterExternal)
+ if (isAttributeExternal && isParameterExternal) {
+ theError = "Both features, attribute and attribute in parameter, are external.";
return false;
+ }
return true;
}