#NEWLINE# def _validate_occurrences( self , occurrences ) : #NEWLINE# #INDENT# DataEntity . validate_datatype ( 'list' , occurrences ) #NEWLINE# for value in occurrences : #NEWLINE# #INDENT# DataEntity . validate_datatype ( 'integer' , value ) #NEWLINE# #UNINDENT# if ( ( len ( occurrences ) != 2 ) or ( not ( 0 <= occurrences [ 0 ] <= occurrences [ 1 ] ) ) or ( occurrences [ 1 ] == 0 ) ) : #NEWLINE# #INDENT# ExceptionCollector . appendException ( InvalidPropertyValueError ( what = occurrences ) )