}
char symbol = value.charAt(0);
if (symbol == '-') {
return new Correction(Integer.parseInt(value.substring(1)), CorrectionsRect.Type.MINUS);
}
else if (symbol == '+') {
return new Correction(Integer.parseInt(value.substring(1)), CorrectionsRect.Type.PLUS);
}
if (symbol == '=') {
return new Correction(Integer.parseInt(value.substring(1)), CorrectionsRect.Type.EQUALS);
}
else {
return new Correction(Integer.parseInt(value), CorrectionsRect.Type.PLUS);
}
}