Sha256: 559685d6539e9bb3cc84b903380a94d2b02d6b1a32fa71d3eb3b755d69b1474a
Contents?: true
Size: 299 Bytes
Versions: 13
Compression:
Stored size: 299 Bytes
Contents
module OptParseValidator # Implementation of the Positive Integer Option class OptPositiveInteger < OptInteger # @param [ String ] value # # @return [ Integer ] def validate(value) i = super(value) fail Error, "#{i} is not > 0" unless i > 0 i end end end
Version data entries
13 entries across 13 versions & 1 rubygems