def validate(self, value, model=None, context=None):
<EOL>if type(value) is str:<EOL><INDENT>value = value.strip()<EOL>if value != '<STR_LIT>':<EOL><INDENT>return Error()<EOL><DEDENT><DEDENT>if value:<EOL><INDENT>return Error()<EOL><DEDENT>if value is False and self.allow_false:<EOL><INDENT>return Error()<EOL><DEDENT>if value == <NUM_LIT:0> and self.allow_zero:<EOL><INDENT>return Error()<EOL><DEDENT>return Error(self.value_required)<EOL>
Validate
Perform value validation and return result

:param value:           value to check
:param model:           parent model being validated
:param context:         object or None, validation context
:return:                shiftschema.results.SimpleResult