Commit b4c6e4ba authored by Alexander Diewald's avatar Alexander Diewald
Browse files

InputValidation: GREEN

Issue-Ref: 3582
Issue-Url: https://af3-developer.fortiss.org/issues/3582

Signed-off-by: Alexander Diewald's avatarAlexander Diewald <diewald@fortiss.org>
parent b785e675
AbstractDecoratedStyledTextCellDatabindingEditingSupport.java a0b06a9bd98ce28da3e5df86b2cb289b5a7a2eab GREEN
AbstractDecoratedTextCellDatabindingEditingSupport.java d82943c0d4000b164beb45b00c64665cdcab2352 GREEN
AbstractStyledTextCellDatabindingEditingSupport.java 6ddea6d5cb18847f202043d9bb2bd8a55ae27a12 GREEN
AbstractTextCellDatabindingEditingSupport.java 8728e78f399a63c11f020fa447c002f42d735771 YELLOW
FloatValidator.java 3173a438f0dc773331be9c7d57478984e1fd52b6 YELLOW
IntValidator.java 934eee306191839be6d319432a1a238ff38c3f66 YELLOW
NumberPositiveValidator.java c45d4433c260e1e7bd4117954221dacb6d2df225 YELLOW
NumberPositiveZeroValidator.java 8ba0dfdcc8b8ad2154f2fb3e6217ff585e59d6e5 YELLOW
NumberValidator.java 04c8ca1abee5fb1f7d7b8d7c61076dde8df76930 YELLOW
NumberValueValidatorBase.java a8cda58d8bba6fdc05c6ac3249dbf1b53fcb0c2b YELLOW
AbstractTextCellDatabindingEditingSupport.java 8728e78f399a63c11f020fa447c002f42d735771 GREEN
FloatValidator.java 3173a438f0dc773331be9c7d57478984e1fd52b6 GREEN
IntValidator.java 934eee306191839be6d319432a1a238ff38c3f66 GREEN
NumberPositiveValidator.java c45d4433c260e1e7bd4117954221dacb6d2df225 GREEN
NumberPositiveZeroValidator.java 8ba0dfdcc8b8ad2154f2fb3e6217ff585e59d6e5 GREEN
NumberValidator.java 1acdc8a42e9d081251c698a90014989733b50120 GREEN
NumberValueValidatorBase.java a8cda58d8bba6fdc05c6ac3249dbf1b53fcb0c2b GREEN
......@@ -25,7 +25,11 @@ import java.text.ParsePosition;
import org.eclipse.core.databinding.validation.IValidator;
import org.eclipse.core.runtime.IStatus;
/** Validates if a given input is a valid {@link Number}. */
/**
* Validates if a given input is a valid {@link Number}.
*
* @author barner
*/
public abstract class NumberValidator implements IValidator {
/** The number format used in the current locale. */
......@@ -54,7 +58,7 @@ public abstract class NumberValidator implements IValidator {
if(trimmedInput.isEmpty()) {
return ok();
}
if(groupingSeparator != null && trimmedInput.indexOf(groupingSeparator) != -1) {
if((groupingSeparator != null) && (trimmedInput.indexOf(groupingSeparator) != -1)) {
return cancel("Grouping separator \'" + groupingSeparator + "\' not allowed");
}
......@@ -63,7 +67,7 @@ public abstract class NumberValidator implements IValidator {
int errorIndex = p.getErrorIndex();
if(errorIndex == -1) {
// In case the input as a valid prefix, the error index will not indicate a problem.
// In case the input has a valid prefix, the error index will not indicate a problem.
// Therefore, check if the entire input was parsed.
if(p.getIndex() < trimmedInput.length()) {
errorIndex = p.getIndex();
......
......@@ -8,7 +8,7 @@ ModelEditorBindingBase.java 4c5ac569c0b6e7678fc8191096b26dfd09fdcb98 GREEN
ModelElementHandlerBase.java 384727748f125c9d43f19d9c0eba4ba1be5a7a26 GREEN
MultiEObjectActionBase.java 9e237d8ea640c4194e4877af4a9cfce88698e543 GREEN
NamedCommentedModelElementHandlerBase.java 681b98b50b362f01abb7a36f108f4f11b9e51829 GREEN
PropertySectionBase.java f9b9f559d678b355ca0854a26972967639a95564 YELLOW
PropertySectionBase.java f9b9f559d678b355ca0854a26972967639a95564 GREEN
TutorialStepUIAtomicBase.java cea2a158158b476de2108d2309afcf47f217b6d9 GREEN
TutorialStepUIAtomicWithWhitelistBase.java a9788ae514f62d27169c737ef59fb583234b5d43 GREEN
TutorialStepUICompositeBase.java 8225210eacb5b88de47d78280c5819f572f00ffa GREEN
......
IdLabeledPropertySection.java 8a360874918ca84a319ae7668011a19cea574148 YELLOW
IdLabeledPropertySection.java 8a360874918ca84a319ae7668011a19cea574148 GREEN
NamedCommentedPropertySection.java d15d490708e5c7362ebc4f30a04bccb0f6b64f39 GREEN
PropertiesAdapterFactory.java edcf34766a60f21c9ba22a1ba73aa487c3d9a946 GREEN
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment