Sha256: aa0ea4bfb567a88309a0da85bfdaef0ea7cee3ae920dd28e16a04f34d2d68433

Contents?: true

Size: 285 Bytes

Versions: 50

Compression:

Stored size: 285 Bytes

Contents

module MCollective
  module Validator
    class LengthValidator
      def self.validate(validator, length)
        if (validator.size > length) && (length > 0)
          raise ValidatorError, "Input string is longer than #{length} character(s)"
        end
      end
    end
  end
end

Version data entries

50 entries across 50 versions & 3 rubygems

Version Path
mcollective-client-2.8.3 lib/mcollective/validator/length_validator.rb
dtk-node-agent-0.7.4.1 mcollective_additions/plugins/v2.2/validator/length_validator.rb
dtk-node-agent-0.7.4 mcollective_additions/plugins/v2.2/validator/length_validator.rb
mcollective-client-2.8.2 lib/mcollective/validator/length_validator.rb
dtk-node-agent-0.7.3 mcollective_additions/plugins/v2.2/validator/length_validator.rb
dtk-node-agent-0.7.2 mcollective_additions/plugins/v2.2/validator/length_validator.rb
dtk-node-agent-0.7.1 mcollective_additions/plugins/v2.2/validator/length_validator.rb
mcollective-client-2.8.1 lib/mcollective/validator/length_validator.rb
dtk-node-agent-0.7.0 mcollective_additions/plugins/v2.2/validator/length_validator.rb
mcollective-client-2.8.0 lib/mcollective/validator/length_validator.rb