origin 1.0.0.rc → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.md +11 -0
- data/LICENSE +20 -0
- data/README.md +50 -0
- data/lib/origin/extensions/array.rb +14 -0
- data/lib/origin/extensions/set.rb +2 -0
- data/lib/origin/selector.rb +3 -0
- data/lib/origin/version.rb +1 -1
- metadata +7 -4
data/CHANGELOG.md
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2011-2012 Durran Jordan
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,50 @@
|
|
1
|
+
Origin [![Build Status](https://secure.travis-ci.org/mongoid/origin.png?branch=master&.png)](http://travis-ci.org/mongoid/origin)
|
2
|
+
========
|
3
|
+
|
4
|
+
Origin is a DSL for building MongoDB queries.
|
5
|
+
|
6
|
+
Project Tracking
|
7
|
+
----------------
|
8
|
+
|
9
|
+
* [Mongoid Google Group](http://groups.google.com/group/mongoid)
|
10
|
+
* [Origin Website and Documentation](http://mongoid.org/en/origin/)
|
11
|
+
|
12
|
+
Compatibility
|
13
|
+
-------------
|
14
|
+
|
15
|
+
Origin is tested against MRI 1.9.2, 1.9.3, 2.0.0, and JRuby (1.9).
|
16
|
+
|
17
|
+
Documentation
|
18
|
+
-------------
|
19
|
+
|
20
|
+
Please see the new Mongoid website for up-to-date documentation in
|
21
|
+
the Origin section: [mongoid.org](http://mongoid.org/en/origin/)
|
22
|
+
|
23
|
+
License
|
24
|
+
-------
|
25
|
+
|
26
|
+
Copyright (c) 2011-2012 Durran Jordan
|
27
|
+
|
28
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
29
|
+
a copy of this software and associated documentation files (the
|
30
|
+
"Software"), to deal in the Software without restriction, including
|
31
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
32
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
33
|
+
permit persons to whom the Software is furnished to do so, subject to
|
34
|
+
the following conditions:
|
35
|
+
|
36
|
+
The above copyright notice and this permission notice shall be
|
37
|
+
included in all copies or substantial portions of the Software.
|
38
|
+
|
39
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
40
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
41
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
42
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
43
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
44
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
45
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
46
|
+
|
47
|
+
Credits
|
48
|
+
-------
|
49
|
+
|
50
|
+
Durran Jordan: durran at gmail dot com
|
@@ -109,6 +109,20 @@ module Origin
|
|
109
109
|
{ first => last.to_direction }
|
110
110
|
end
|
111
111
|
|
112
|
+
# Update all the values in the hash with the provided block.
|
113
|
+
#
|
114
|
+
# @example Update the values in place.
|
115
|
+
# [ 1, 2, 3 ].update_values(&:to_s)
|
116
|
+
#
|
117
|
+
# @param [ Proc ] block The block to execute on each value.
|
118
|
+
#
|
119
|
+
# @return [ Array ] the array.
|
120
|
+
#
|
121
|
+
# @since 1.0.0
|
122
|
+
def update_values(&block)
|
123
|
+
replace(map(&block))
|
124
|
+
end
|
125
|
+
|
112
126
|
private
|
113
127
|
|
114
128
|
# Converts the array to a multi-dimensional array.
|
data/lib/origin/selector.rb
CHANGED
data/lib/origin/version.rb
CHANGED
metadata
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: origin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0
|
5
|
-
prerelease:
|
4
|
+
version: 1.0.0
|
5
|
+
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Durran Jordan
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-05
|
12
|
+
date: 2012-06-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -127,6 +127,9 @@ files:
|
|
127
127
|
- lib/origin/smash.rb
|
128
128
|
- lib/origin/version.rb
|
129
129
|
- lib/origin.rb
|
130
|
+
- CHANGELOG.md
|
131
|
+
- LICENSE
|
132
|
+
- README.md
|
130
133
|
- Rakefile
|
131
134
|
homepage: http://mongoid.org
|
132
135
|
licenses: []
|
@@ -142,7 +145,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
142
145
|
version: '0'
|
143
146
|
segments:
|
144
147
|
- 0
|
145
|
-
hash: -
|
148
|
+
hash: -778932131334871158
|
146
149
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
147
150
|
none: false
|
148
151
|
requirements:
|