sugarcube 0.7.7 → 0.7.9
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +1 -1
- data/lib/sugarcube/array.rb +13 -1
- data/lib/sugarcube/nsindexpath.rb +11 -0
- data/lib/sugarcube/nsindexset.rb +11 -0
- data/lib/sugarcube/version.rb +1 -1
- metadata +7 -5
data/README.md
CHANGED
data/lib/sugarcube/array.rb
CHANGED
@@ -8,7 +8,7 @@ class Array
|
|
8
8
|
ret
|
9
9
|
end
|
10
10
|
|
11
|
-
def
|
11
|
+
def nsindexpath
|
12
12
|
if self.length == 0
|
13
13
|
raise "An index path must have at least one index"
|
14
14
|
end
|
@@ -24,4 +24,16 @@ class Array
|
|
24
24
|
return path
|
25
25
|
end
|
26
26
|
|
27
|
+
def nsindexset
|
28
|
+
if self.length == 0
|
29
|
+
raise "An index set must have at least one index"
|
30
|
+
end
|
31
|
+
|
32
|
+
set = NSMutableIndexSet.indexSet
|
33
|
+
self.each do |val|
|
34
|
+
set.addIndex val
|
35
|
+
end
|
36
|
+
set
|
37
|
+
end
|
38
|
+
|
27
39
|
end
|
data/lib/sugarcube/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sugarcube
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.9
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -14,7 +14,7 @@ date: 2012-08-27 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rake
|
17
|
-
requirement: &
|
17
|
+
requirement: &70196039902580 !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ! '>='
|
@@ -22,10 +22,10 @@ dependencies:
|
|
22
22
|
version: '0'
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
|
-
version_requirements: *
|
25
|
+
version_requirements: *70196039902580
|
26
26
|
- !ruby/object:Gem::Dependency
|
27
27
|
name: rspec
|
28
|
-
requirement: &
|
28
|
+
requirement: &70196039901960 !ruby/object:Gem::Requirement
|
29
29
|
none: false
|
30
30
|
requirements:
|
31
31
|
- - ! '>='
|
@@ -33,7 +33,7 @@ dependencies:
|
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
|
-
version_requirements: *
|
36
|
+
version_requirements: *70196039901960
|
37
37
|
description: ! 'CocoaTouch/iOS is a *verbose* framework. These extensions hope to
|
38
38
|
make
|
39
39
|
|
@@ -72,6 +72,8 @@ files:
|
|
72
72
|
- lib/sugarcube/exceptions.rb
|
73
73
|
- lib/sugarcube/fixnum.rb
|
74
74
|
- lib/sugarcube/notifications.rb
|
75
|
+
- lib/sugarcube/nsindexpath.rb
|
76
|
+
- lib/sugarcube/nsindexset.rb
|
75
77
|
- lib/sugarcube/nsstring.rb
|
76
78
|
- lib/sugarcube/nsurl.rb
|
77
79
|
- lib/sugarcube/numeric.rb
|