dronestream 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/README.md +11 -3
- data/lib/dronestream/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 622c19502dd816dbaf4908c445f5a6cae93f7d5c
|
4
|
+
data.tar.gz: 13aa673acbe285fec0cafefe400c502ba09abad9
|
5
5
|
!binary "U0hBNTEy":
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4b631866b13dfafd325094898ce5eb1bd0bccd30e657d4cb2cb1c1bf6ff05466b9fc82bb99894111f141b7cc5fd54f0ced110251b35abae6dbd02203593edb88
|
7
|
+
data.tar.gz: ce2a2637ad2225bc8e52e72a43ba5d59bbe39367f64f376f3468256f7ac7b1bc434d13b7732ace1524557c2e5c40eb6ad442049fd30b010a482d1eac84871c39
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,7 @@
|
|
1
|
+
## 0.2.3 (June 7, 2013)
|
2
|
+
|
3
|
+
* This version contains *breaking changes* from the previous version, and allows method chaining. The return value of all queries is different from previous versions, and the interface is completely different. Version 0.2.3 effectively deprecates all previous versions.
|
4
|
+
|
1
5
|
## 0.1.1 (June 4, 2013)
|
2
6
|
|
3
7
|
* Fix bug in `with_child_casualties`. That method now correctly returns an array, rather than throwing an error.
|
@@ -10,4 +14,8 @@
|
|
10
14
|
|
11
15
|
* Initial release. Support for `#in_country` and `#with_civilian_casualties` methods only.
|
12
16
|
|
17
|
+
## Other versions?
|
18
|
+
|
19
|
+
You may notice that the versions are not as predictably sequential as you would think (e.g., 0.1.1 to 0.2.3). I had some issues with a few builds that I had to yank from rubygems.com, and had to use diffrent version names.
|
20
|
+
|
13
21
|
|
data/README.md
CHANGED
@@ -27,13 +27,21 @@ require 'dronestream'
|
|
27
27
|
#=> true
|
28
28
|
```
|
29
29
|
|
30
|
-
Then, you can find
|
30
|
+
Then, you can find strikes by a number of criteria. Version 0.2.3 allows you to chain methods together to combine data points in your query. However, each query returns an instance of the class. To get the data out in a usable format (say, for looping over), simply call `to_a` on the return value of your query.
|
31
31
|
|
32
32
|
```ruby
|
33
|
-
Dronestream::Strike.in_country('Yemen')
|
34
|
-
#=>
|
33
|
+
>> Dronestream::Strike.in_country('Yemen')
|
34
|
+
#=> Dronestream::Strike
|
35
|
+
>> Dronestream::Strike.in_country('Yemen').to_a
|
36
|
+
#=> [{"_id"=>"51a65578e0932c0e1eb4199f", "number"=>1, "country"=>"Yemen", "date"=>"2002-11-03T00:00:00.000Z", "town"=>"", "location"=>"Marib Province", "deaths"=>"6", "deaths_min"=>"6", "deaths_max"=>"6", "civilians"=>"0", "injuries"=>""...
|
37
|
+
|
38
|
+
>> yemini_strikes_with_civilian_casualties = Dronestream::Strike.in_country('Yemen').with_civilian_casualties
|
39
|
+
#=> Dronestream::Strike
|
40
|
+
>> yemini_strikes_with_civilian_casualties.to_a
|
41
|
+
#=> [{"_id"=>"51a6557ae0932c0e1eb41aad", "number"=>271, "country"=>"Yemen", "date"=>"2011-06-03T00:00:00.000Z", "town"=>"Zinjibar", "location"=>"Abyan Province", "deaths"=>"7", "deaths_min"=>"7", "deaths_max"=>"7", "civilians"=>"4", "injuries"=>""
|
35
42
|
```
|
36
43
|
|
44
|
+
|
37
45
|
## Contributing
|
38
46
|
|
39
47
|
1. Fork it
|
data/lib/dronestream/version.rb
CHANGED