<commit_before>import Ember from 'ember';

import RequiredValidator from 'ember-simple-validate/lib/validators/required';
import RegexValidator from 'ember-simple-validate/lib/validators/regex';
import DateValidator from 'ember-simple-validate/lib/validators/date';
import IntegerValidator from 'ember-simple-validate/lib/validators/integer';
import MaxLengthValidator from 'ember-simple-validate/lib/validators/max-length';

export default Ember.Object.extend({
  required: function() {
    return RequiredValidator.create();
  },

  regex: function(pattern) {
    return RegexValidator.create().with({
      pattern: pattern
    });
  },

  date: function() {
    return DateValidator.create();
  },

  integer: function(options) {
    return IntegerValidator.create().with(options);
  },

  maxLength: function(max) {
    return MaxLengthValidator.create().with({
      max: max
    });
  }
});<commit_msg>Register numeric validator<commit_after>import Ember from 'ember';

import RequiredValidator from 'ember-simple-validate/lib/validators/required';
import RegexValidator from 'ember-simple-validate/lib/validators/regex';
import DateValidator from 'ember-simple-validate/lib/validators/date';
import NumericValidator from 'ember-simple-validate/lib/validators/numeric';
import IntegerValidator from 'ember-simple-validate/lib/validators/integer';
import MaxLengthValidator from 'ember-simple-validate/lib/validators/max-length';

export default Ember.Object.extend({
  required: function() {
    return RequiredValidator.create();
  },

  regex: function(pattern) {
    return RegexValidator.create().with({
      pattern: pattern
    });
  },

  date: function() {
    return DateValidator.create();
  },

  numeric: function(options) {
    return NumericValidator.create().with(options);
  },

  integer: function(options) {
    return IntegerValidator.create().with(options);
  },

  maxLength: function(max) {
    return MaxLengthValidator.create().with({
      max: max
    });
  }
});
{'fraction_non_alphanumeric': 0.128693039559339, 'fraction_numerical': 0.0, 'mean_word_length': 4.5654596100278555, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6417362', 'n_tokens_mistral': 562, 'n_tokens_neox': 550, 'n_words': 112}