omg_validator 0.0.6.2 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. data/.yardoc/checksums +15 -15
  2. data/.yardoc/objects/root.dat +0 -0
  3. data/Gemfile +1 -0
  4. data/Gemfile.lock +25 -25
  5. data/doc/OmgValidator.html +6 -4
  6. data/doc/OmgValidator/Validators.html +6 -4
  7. data/doc/OmgValidator/Validators/AlphaDashValidator.html +14 -10
  8. data/doc/OmgValidator/Validators/AlphaNumericValidator.html +14 -10
  9. data/doc/OmgValidator/Validators/AlphaValidator.html +14 -10
  10. data/doc/OmgValidator/Validators/DateValidator.html +5 -5
  11. data/doc/OmgValidator/Validators/DecimalValidator.html +13 -10
  12. data/doc/OmgValidator/Validators/EmailValidator.html +15 -11
  13. data/doc/OmgValidator/Validators/IntegerValidator.html +14 -10
  14. data/doc/OmgValidator/Validators/IpAddressValidator.html +15 -11
  15. data/doc/OmgValidator/Validators/NumericValidator.html +13 -10
  16. data/doc/OmgValidator/Validators/PhoneNumberValidator.html +15 -11
  17. data/doc/OmgValidator/Validators/PostalCodeValidator.html +14 -10
  18. data/doc/OmgValidator/Validators/PostalOrZipCodeValidator.html +14 -10
  19. data/doc/OmgValidator/Validators/StrongPasswordValidator.html +18 -13
  20. data/doc/OmgValidator/Validators/UrlValidator.html +17 -11
  21. data/doc/OmgValidator/Validators/ZipCodeValidator.html +13 -10
  22. data/doc/_index.html +4 -4
  23. data/doc/file.README.html +11 -13
  24. data/doc/frames.html +1 -1
  25. data/doc/index.html +11 -13
  26. data/doc/js/full_list.js +6 -0
  27. data/doc/method_list.html +12 -12
  28. data/doc/top-level-namespace.html +5 -3
  29. data/lib/omg_validator.rb +3 -0
  30. data/lib/omg_validator/validators/alpha_dash_validator.rb +3 -0
  31. data/lib/omg_validator/validators/alpha_numeric_validator.rb +3 -0
  32. data/lib/omg_validator/validators/alpha_validator.rb +3 -0
  33. data/lib/omg_validator/validators/decimal_validator.rb +3 -0
  34. data/lib/omg_validator/validators/email_validator.rb +4 -1
  35. data/lib/omg_validator/validators/integer_validator.rb +3 -0
  36. data/lib/omg_validator/validators/ip_address_validator.rb +4 -1
  37. data/lib/omg_validator/validators/numeric_validator.rb +3 -0
  38. data/lib/omg_validator/validators/phone_number_validator.rb +4 -1
  39. data/lib/omg_validator/validators/postal_code_validator.rb +3 -0
  40. data/lib/omg_validator/validators/postal_or_zip_code_validator.rb +3 -0
  41. data/lib/omg_validator/validators/strong_password_validator.rb +6 -3
  42. data/lib/omg_validator/validators/url_validator.rb +5 -2
  43. data/lib/omg_validator/validators/zip_code_validator.rb +3 -0
  44. data/lib/omg_validator/version.rb +1 -1
  45. data/omg_validator-0.0.6.2.gem +0 -0
  46. data/test/dummy/app/models/thing.rb +32 -0
  47. data/test/dummy/config/environments/test.rb +1 -1
  48. data/test/omg_validator_test.rb +248 -0
  49. data/test/support/things.rb +252 -0
  50. metadata +7 -2
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: OmgValidator::Validators::StrongPasswordValidator
8
8
 
9
- &mdash; Documentation by YARD 0.7.4
9
+ &mdash; Documentation by YARD 0.7.5
10
10
 
11
11
  </title>
12
12
 
@@ -98,10 +98,15 @@
98
98
  <div class="discussion">
99
99
  <p>
100
100
  Checks whether password input is a strong password Must contain a least one
101
- number, one lower case letter and one upper case letter
101
+ number, one lower case letter and one upper case letter and must be at
102
+ least 8 characters
102
103
  </p>
103
104
  <p>
104
105
  validates :password, strong_password: true
106
+ </p>
107
+ <p>
108
+ matches: ASdj3j3jsS, 8#adCje3, pwd#fdJa9, To34zNbsr30, does not match:
109
+ password, sdfsdfs3, Jsdsdsdj, G3hn$h
105
110
  </p>
106
111
 
107
112
 
@@ -112,10 +117,10 @@ validates :password, strong_password: true
112
117
 
113
118
  </div>
114
119
 
115
-
116
120
 
117
121
 
118
-
122
+
123
+
119
124
 
120
125
 
121
126
  <h2>
@@ -169,22 +174,22 @@ validates :password, strong_password: true
169
174
  <pre class="lines">
170
175
 
171
176
 
172
- 8
173
- 9
174
- 10
175
177
  11
176
178
  12
177
179
  13
178
- 14</pre>
180
+ 14
181
+ 15
182
+ 16
183
+ 17</pre>
179
184
  </td>
180
185
  <td>
181
- <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/strong_password_validator.rb', line 8</span>
186
+ <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/strong_password_validator.rb', line 11</span>
182
187
 
183
188
  <span class='kw'>def</span> <span class='id identifier rubyid_validate_each'>validate_each</span><span class='lparen'>(</span><span class='id identifier rubyid_record'>record</span><span class='comma'>,</span> <span class='id identifier rubyid_attribute'>attribute</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
184
189
  <span class='kw'>return</span> <span class='kw'>nil</span> <span class='kw'>if</span> <span class='id identifier rubyid_value'>value</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
185
- <span class='id identifier rubyid_reg'>reg</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>/^\w*(?=\w*\d)(?=\w*[a-z])(?=\w*[A-Z])\w*$/</span><span class='tstring_end'>'</span></span>
190
+ <span class='id identifier rubyid_reg'>reg</span> <span class='op'>=</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>(?=^.{8,}$)((?=.*\d)|(?=.*\W+))(?![.\n])(?=.*[A-Z])(?=.*[a-z]).*$</span><span class='regexp_end'>/</span></span>
186
191
  <span class='kw'>unless</span> <span class='id identifier rubyid_reg'>reg</span><span class='period'>.</span><span class='id identifier rubyid_match'>match</span><span class='lparen'>(</span><span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
187
- <span class='id identifier rubyid_record'>record</span><span class='period'>.</span><span class='id identifier rubyid_errors'>errors</span><span class='lbracket'>[</span><span class='id identifier rubyid_attribute'>attribute</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>must contain at least a number, a lower case letter, and a upper case letter</span><span class='tstring_end'>&quot;</span></span>
192
+ <span class='id identifier rubyid_record'>record</span><span class='period'>.</span><span class='id identifier rubyid_errors'>errors</span><span class='lbracket'>[</span><span class='id identifier rubyid_attribute'>attribute</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>must contain at least a number, a lower case letter, a upper case letter and must be at least 8 characters</span><span class='tstring_end'>&quot;</span></span>
188
193
  <span class='kw'>end</span>
189
194
  <span class='kw'>end</span></pre>
190
195
  </td>
@@ -197,9 +202,9 @@ validates :password, strong_password: true
197
202
  </div>
198
203
 
199
204
  <div id="footer">
200
- Generated on Fri Mar 30 11:50:31 2012 by
205
+ Generated on Thu Apr 5 00:05:42 2012 by
201
206
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
202
- 0.7.4 (ruby-1.9.2).
207
+ 0.7.5 (ruby-1.9.2).
203
208
  </div>
204
209
 
205
210
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: OmgValidator::Validators::UrlValidator
8
8
 
9
- &mdash; Documentation by YARD 0.7.4
9
+ &mdash; Documentation by YARD 0.7.5
10
10
 
11
11
  </title>
12
12
 
@@ -102,6 +102,12 @@ ftp
102
102
  </p>
103
103
  <p>
104
104
  validates :url, url: true
105
+ </p>
106
+ <p>
107
+ matches: <a href="http://www.example.com">www.example.com</a>, <a
108
+ href="http://www.example.com">www.example.com</a>, example.com,
109
+ sub.example.com does not match: @asd.com, domain.c, domain.asd.,
110
+ amasd@asd.com.a
105
111
  </p>
106
112
 
107
113
 
@@ -112,10 +118,10 @@ validates :url, url: true
112
118
 
113
119
  </div>
114
120
 
115
-
116
121
 
117
122
 
118
-
123
+
124
+
119
125
 
120
126
 
121
127
  <h2>
@@ -169,20 +175,20 @@ validates :url, url: true
169
175
  <pre class="lines">
170
176
 
171
177
 
172
- 8
173
- 9
174
- 10
175
178
  11
176
179
  12
177
180
  13
178
- 14</pre>
181
+ 14
182
+ 15
183
+ 16
184
+ 17</pre>
179
185
  </td>
180
186
  <td>
181
- <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/url_validator.rb', line 8</span>
187
+ <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/url_validator.rb', line 11</span>
182
188
 
183
189
  <span class='kw'>def</span> <span class='id identifier rubyid_validate_each'>validate_each</span><span class='lparen'>(</span><span class='id identifier rubyid_record'>record</span><span class='comma'>,</span> <span class='id identifier rubyid_attribute'>attribute</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
184
190
  <span class='kw'>return</span> <span class='kw'>nil</span> <span class='kw'>if</span> <span class='id identifier rubyid_value'>value</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
185
- <span class='id identifier rubyid_reg'>reg</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>`.*?((http|ftp|https)://[\w#$&amp;+,\/:;=?@.-]+)[^\w#$&amp;+,\/:;=?@.-]*?`i</span><span class='tstring_end'>'</span></span>
191
+ <span class='id identifier rubyid_reg'>reg</span> <span class='op'>=</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>^((https?):\/\/)?([a-z\d]+([\-\.][a-z\d]+)*\.[a-z]{2,6})((:(\d{1,5}))?(\/.*)?)?$</span><span class='regexp_end'>/</span></span>
186
192
  <span class='kw'>unless</span> <span class='id identifier rubyid_reg'>reg</span><span class='period'>.</span><span class='id identifier rubyid_match'>match</span><span class='lparen'>(</span><span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
187
193
  <span class='id identifier rubyid_record'>record</span><span class='period'>.</span><span class='id identifier rubyid_errors'>errors</span><span class='lbracket'>[</span><span class='id identifier rubyid_attribute'>attribute</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>must be a valid url</span><span class='tstring_end'>&quot;</span></span>
188
194
  <span class='kw'>end</span>
@@ -197,9 +203,9 @@ validates :url, url: true
197
203
  </div>
198
204
 
199
205
  <div id="footer">
200
- Generated on Fri Mar 30 11:50:31 2012 by
206
+ Generated on Thu Apr 5 00:05:42 2012 by
201
207
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
202
- 0.7.4 (ruby-1.9.2).
208
+ 0.7.5 (ruby-1.9.2).
203
209
  </div>
204
210
 
205
211
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: OmgValidator::Validators::ZipCodeValidator
8
8
 
9
- &mdash; Documentation by YARD 0.7.4
9
+ &mdash; Documentation by YARD 0.7.5
10
10
 
11
11
  </title>
12
12
 
@@ -101,6 +101,9 @@ Checks whether input is a valid zip code
101
101
  </p>
102
102
  <p>
103
103
  validates :zip_code, zip_code: true
104
+ </p>
105
+ <p>
106
+ matches: 90210, 20037-8001, 12345 does not match: 123456, 20037-001, 207-01
104
107
  </p>
105
108
 
106
109
 
@@ -111,10 +114,10 @@ validates :zip_code, zip_code: true
111
114
 
112
115
  </div>
113
116
 
114
-
115
117
 
116
118
 
117
-
119
+
120
+
118
121
 
119
122
 
120
123
  <h2>
@@ -168,16 +171,16 @@ validates :zip_code, zip_code: true
168
171
  <pre class="lines">
169
172
 
170
173
 
171
- 7
172
- 8
173
- 9
174
174
  10
175
175
  11
176
176
  12
177
- 13</pre>
177
+ 13
178
+ 14
179
+ 15
180
+ 16</pre>
178
181
  </td>
179
182
  <td>
180
- <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/zip_code_validator.rb', line 7</span>
183
+ <pre class="code"><span class="info file"># File 'lib/omg_validator/validators/zip_code_validator.rb', line 10</span>
181
184
 
182
185
  <span class='kw'>def</span> <span class='id identifier rubyid_validate_each'>validate_each</span><span class='lparen'>(</span><span class='id identifier rubyid_record'>record</span><span class='comma'>,</span> <span class='id identifier rubyid_attribute'>attribute</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
183
186
  <span class='kw'>return</span> <span class='kw'>nil</span> <span class='kw'>if</span> <span class='id identifier rubyid_value'>value</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
@@ -196,9 +199,9 @@ validates :zip_code, zip_code: true
196
199
  </div>
197
200
 
198
201
  <div id="footer">
199
- Generated on Fri Mar 30 11:50:31 2012 by
202
+ Generated on Thu Apr 5 00:05:42 2012 by
200
203
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
201
- 0.7.4 (ruby-1.9.2).
204
+ 0.7.5 (ruby-1.9.2).
202
205
  </div>
203
206
 
204
207
  </body>
@@ -4,7 +4,7 @@
4
4
  <head>
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>
7
- Documentation by YARD 0.7.4
7
+ Documentation by YARD 0.7.5
8
8
 
9
9
  </title>
10
10
 
@@ -52,7 +52,7 @@
52
52
 
53
53
  <iframe id="search_frame"></iframe>
54
54
 
55
- <div id="content"><h1 class="noborder title">Documentation by YARD 0.7.4</h1>
55
+ <div id="content"><h1 class="noborder title">Documentation by YARD 0.7.5</h1>
56
56
  <div id="listing">
57
57
  <h1 class="alphaindex">Alphabetic Index</h1>
58
58
 
@@ -292,9 +292,9 @@
292
292
  </div>
293
293
 
294
294
  <div id="footer">
295
- Generated on Fri Mar 30 11:50:31 2012 by
295
+ Generated on Thu Apr 5 00:05:42 2012 by
296
296
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
297
- 0.7.4 (ruby-1.9.2).
297
+ 0.7.5 (ruby-1.9.2).
298
298
  </div>
299
299
 
300
300
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  File: README
8
8
 
9
- &mdash; Documentation by YARD 0.7.4
9
+ &mdash; Documentation by YARD 0.7.5
10
10
 
11
11
  </title>
12
12
 
@@ -75,18 +75,17 @@
75
75
  <li>US (or compatible) Zip Code</li>
76
76
  </ul>
77
77
 
78
-
79
78
  <p>Using the gem is easy. Just add it to your gemfile.</p>
80
79
 
81
- <p> gem "omg_validator", "~> 0.0.4"</p>
80
+ <p>gem &quot;omg_validator&quot;, &quot;~&gt; 0.0.4&quot;</p>
82
81
 
83
82
  <p>Run bundle install and then use them in your models. For example:</p>
84
83
 
85
- <p> validates :postal_code, postal_or_zip_code: true</p>
84
+ <p>validates :postal<em>code, postal</em>or<em>zip</em>code: true</p>
86
85
 
87
- <p>Think of this package as a swiss army knife for your validation needs. It larges replaces the need to use validates_format_of validation helper method.</p>
86
+ <p>Think of this package as a swiss army knife for your validation needs. It larges replaces the need to use validates<em>format</em>of validation helper method. </p>
88
87
 
89
- <p>The decimal, integer, and numeric validators do overlap with functionality in the validates_numericality_of validation helper method. We have kept these in the gem however, as we personally find them easier to use. The validates_numericality_of method is still immensely useful for more complex numeric validations.</p>
88
+ <p>The decimal, integer, and numeric validators do overlap with functionality in the validates<em>numericality</em>of validation helper method. We have kept these in the gem however, as we personally find them easier to use. The validates<em>numericality</em>of method is still immensely useful for more complex numeric validations.</p>
90
89
 
91
90
  <h3>Contributors</h3>
92
91
 
@@ -95,30 +94,29 @@
95
94
  <li>Michael Mottola</li>
96
95
  </ul>
97
96
 
98
-
99
97
  <h3>How to Contribute</h3>
100
98
 
101
99
  <p>This project is in active development. We are using it in real world projects; some parts work well, and others need more work. In other words; test it before using it.</p>
102
100
 
103
- <p>We released it hoping that others would find it useful. We encourage you to fork the project and improve on it. We would be most gracious if you send a pull request with your modifications. We will include you in the list of contributors unless you request to not be listed.</p>
101
+ <p>We released it hoping that others would find it useful. We encourage you to fork the project and improve on it. We would be most gracious if you send a pull request with your modifications. We will include you in the list of contributors unless you request to not be listed. </p>
104
102
 
105
- <p>The source code for this project is here: <a href="https://github.com/llwebsol/OmgValidators.">https://github.com/llwebsol/OmgValidators.</a></p>
103
+ <p>The source code for this project is here: <a href="https://github.com/llwebsol/OmgValidators">https://github.com/llwebsol/OmgValidators</a>. </p>
106
104
 
107
105
  <h3>License</h3>
108
106
 
109
107
  <p>Copyright (c) 2011-2012 Nickolas Kenyeres, Michael Mottola.</p>
110
108
 
111
- <p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p>
109
+ <p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the &quot;Software&quot;), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p>
112
110
 
113
111
  <p>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</p>
114
112
 
115
- <p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
113
+ <p>THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
116
114
  </div></div>
117
115
 
118
116
  <div id="footer">
119
- Generated on Fri Mar 30 11:50:31 2012 by
117
+ Generated on Thu Apr 5 00:05:42 2012 by
120
118
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
121
- 0.7.4 (ruby-1.9.2).
119
+ 0.7.5 (ruby-1.9.2).
122
120
  </div>
123
121
 
124
122
  </body>
@@ -4,7 +4,7 @@
4
4
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5
5
  <head>
6
6
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
7
- <title>Documentation by YARD 0.7.4</title>
7
+ <title>Documentation by YARD 0.7.5</title>
8
8
  </head>
9
9
  <frameset cols="20%,*">
10
10
  <frame name="list" src="class_list.html" />
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  File: README
8
8
 
9
- &mdash; Documentation by YARD 0.7.4
9
+ &mdash; Documentation by YARD 0.7.5
10
10
 
11
11
  </title>
12
12
 
@@ -75,18 +75,17 @@
75
75
  <li>US (or compatible) Zip Code</li>
76
76
  </ul>
77
77
 
78
-
79
78
  <p>Using the gem is easy. Just add it to your gemfile.</p>
80
79
 
81
- <p> gem "omg_validator", "~> 0.0.4"</p>
80
+ <p>gem &quot;omg_validator&quot;, &quot;~&gt; 0.0.4&quot;</p>
82
81
 
83
82
  <p>Run bundle install and then use them in your models. For example:</p>
84
83
 
85
- <p> validates :postal_code, postal_or_zip_code: true</p>
84
+ <p>validates :postal<em>code, postal</em>or<em>zip</em>code: true</p>
86
85
 
87
- <p>Think of this package as a swiss army knife for your validation needs. It larges replaces the need to use validates_format_of validation helper method.</p>
86
+ <p>Think of this package as a swiss army knife for your validation needs. It larges replaces the need to use validates<em>format</em>of validation helper method. </p>
88
87
 
89
- <p>The decimal, integer, and numeric validators do overlap with functionality in the validates_numericality_of validation helper method. We have kept these in the gem however, as we personally find them easier to use. The validates_numericality_of method is still immensely useful for more complex numeric validations.</p>
88
+ <p>The decimal, integer, and numeric validators do overlap with functionality in the validates<em>numericality</em>of validation helper method. We have kept these in the gem however, as we personally find them easier to use. The validates<em>numericality</em>of method is still immensely useful for more complex numeric validations.</p>
90
89
 
91
90
  <h3>Contributors</h3>
92
91
 
@@ -95,30 +94,29 @@
95
94
  <li>Michael Mottola</li>
96
95
  </ul>
97
96
 
98
-
99
97
  <h3>How to Contribute</h3>
100
98
 
101
99
  <p>This project is in active development. We are using it in real world projects; some parts work well, and others need more work. In other words; test it before using it.</p>
102
100
 
103
- <p>We released it hoping that others would find it useful. We encourage you to fork the project and improve on it. We would be most gracious if you send a pull request with your modifications. We will include you in the list of contributors unless you request to not be listed.</p>
101
+ <p>We released it hoping that others would find it useful. We encourage you to fork the project and improve on it. We would be most gracious if you send a pull request with your modifications. We will include you in the list of contributors unless you request to not be listed. </p>
104
102
 
105
- <p>The source code for this project is here: <a href="https://github.com/llwebsol/OmgValidators.">https://github.com/llwebsol/OmgValidators.</a></p>
103
+ <p>The source code for this project is here: <a href="https://github.com/llwebsol/OmgValidators">https://github.com/llwebsol/OmgValidators</a>. </p>
106
104
 
107
105
  <h3>License</h3>
108
106
 
109
107
  <p>Copyright (c) 2011-2012 Nickolas Kenyeres, Michael Mottola.</p>
110
108
 
111
- <p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p>
109
+ <p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the &quot;Software&quot;), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p>
112
110
 
113
111
  <p>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</p>
114
112
 
115
- <p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
113
+ <p>THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
116
114
  </div></div>
117
115
 
118
116
  <div id="footer">
119
- Generated on Fri Mar 30 11:50:31 2012 by
117
+ Generated on Thu Apr 5 00:05:42 2012 by
120
118
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
121
- 0.7.4 (ruby-1.9.2).
119
+ 0.7.5 (ruby-1.9.2).
122
120
  </div>
123
121
 
124
122
  </body>
@@ -4,6 +4,9 @@ var searchCache = [];
4
4
  var searchString = '';
5
5
  var regexSearchString = '';
6
6
  var caseSensitiveMatch = false;
7
+ var ignoreKeyCodeMin = 8;
8
+ var ignoreKeyCodeMax = 46;
9
+ var commandKey = 91;
7
10
 
8
11
  RegExp.escape = function(text) {
9
12
  return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
@@ -19,6 +22,9 @@ function fullListSearch() {
19
22
  });
20
23
 
21
24
  $('#search input').keyup(function() {
25
+ if ((event.keyCode > ignoreKeyCodeMin && event.keyCode < ignoreKeyCodeMax)
26
+ || event.keyCode == commandKey)
27
+ return;
22
28
  searchString = this.value;
23
29
  caseSensitiveMatch = searchString.match(/[A-Z]/) != null;
24
30
  regexSearchString = RegExp.escape(searchString);
@@ -57,25 +57,25 @@
57
57
 
58
58
 
59
59
  <li class="r1 ">
60
- <span class='object_link'><a href="OmgValidator/Validators/AlphaValidator.html#validate_each-instance_method" title="OmgValidator::Validators::AlphaValidator#validate_each (method)">#validate_each</a></span>
60
+ <span class='object_link'><a href="OmgValidator/Validators/EmailValidator.html#validate_each-instance_method" title="OmgValidator::Validators::EmailValidator#validate_each (method)">#validate_each</a></span>
61
61
 
62
- <small>OmgValidator::Validators::AlphaValidator</small>
62
+ <small>OmgValidator::Validators::EmailValidator</small>
63
63
 
64
64
  </li>
65
65
 
66
66
 
67
67
  <li class="r2 ">
68
- <span class='object_link'><a href="OmgValidator/Validators/EmailValidator.html#validate_each-instance_method" title="OmgValidator::Validators::EmailValidator#validate_each (method)">#validate_each</a></span>
68
+ <span class='object_link'><a href="OmgValidator/Validators/AlphaValidator.html#validate_each-instance_method" title="OmgValidator::Validators::AlphaValidator#validate_each (method)">#validate_each</a></span>
69
69
 
70
- <small>OmgValidator::Validators::EmailValidator</small>
70
+ <small>OmgValidator::Validators::AlphaValidator</small>
71
71
 
72
72
  </li>
73
73
 
74
74
 
75
75
  <li class="r1 ">
76
- <span class='object_link'><a href="OmgValidator/Validators/IntegerValidator.html#validate_each-instance_method" title="OmgValidator::Validators::IntegerValidator#validate_each (method)">#validate_each</a></span>
76
+ <span class='object_link'><a href="OmgValidator/Validators/NumericValidator.html#validate_each-instance_method" title="OmgValidator::Validators::NumericValidator#validate_each (method)">#validate_each</a></span>
77
77
 
78
- <small>OmgValidator::Validators::IntegerValidator</small>
78
+ <small>OmgValidator::Validators::NumericValidator</small>
79
79
 
80
80
  </li>
81
81
 
@@ -89,9 +89,9 @@
89
89
 
90
90
 
91
91
  <li class="r1 ">
92
- <span class='object_link'><a href="OmgValidator/Validators/NumericValidator.html#validate_each-instance_method" title="OmgValidator::Validators::NumericValidator#validate_each (method)">#validate_each</a></span>
92
+ <span class='object_link'><a href="OmgValidator/Validators/IntegerValidator.html#validate_each-instance_method" title="OmgValidator::Validators::IntegerValidator#validate_each (method)">#validate_each</a></span>
93
93
 
94
- <small>OmgValidator::Validators::NumericValidator</small>
94
+ <small>OmgValidator::Validators::IntegerValidator</small>
95
95
 
96
96
  </li>
97
97
 
@@ -105,17 +105,17 @@
105
105
 
106
106
 
107
107
  <li class="r1 ">
108
- <span class='object_link'><a href="OmgValidator/Validators/AlphaDashValidator.html#validate_each-instance_method" title="OmgValidator::Validators::AlphaDashValidator#validate_each (method)">#validate_each</a></span>
108
+ <span class='object_link'><a href="OmgValidator/Validators/IpAddressValidator.html#validate_each-instance_method" title="OmgValidator::Validators::IpAddressValidator#validate_each (method)">#validate_each</a></span>
109
109
 
110
- <small>OmgValidator::Validators::AlphaDashValidator</small>
110
+ <small>OmgValidator::Validators::IpAddressValidator</small>
111
111
 
112
112
  </li>
113
113
 
114
114
 
115
115
  <li class="r2 ">
116
- <span class='object_link'><a href="OmgValidator/Validators/IpAddressValidator.html#validate_each-instance_method" title="OmgValidator::Validators::IpAddressValidator#validate_each (method)">#validate_each</a></span>
116
+ <span class='object_link'><a href="OmgValidator/Validators/AlphaDashValidator.html#validate_each-instance_method" title="OmgValidator::Validators::AlphaDashValidator#validate_each (method)">#validate_each</a></span>
117
117
 
118
- <small>OmgValidator::Validators::IpAddressValidator</small>
118
+ <small>OmgValidator::Validators::AlphaDashValidator</small>
119
119
 
120
120
  </li>
121
121