xmlmapper 0.5.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG.md +35 -0
  3. data/README.md +605 -0
  4. data/lib/happymapper.rb +776 -0
  5. data/lib/happymapper/anonymous_mapper.rb +114 -0
  6. data/lib/happymapper/attribute.rb +21 -0
  7. data/lib/happymapper/element.rb +55 -0
  8. data/lib/happymapper/item.rb +160 -0
  9. data/lib/happymapper/supported_types.rb +140 -0
  10. data/lib/happymapper/text_node.rb +8 -0
  11. data/lib/happymapper/version.rb +3 -0
  12. data/lib/xmlmapper.rb +1 -0
  13. data/spec/attribute_default_value_spec.rb +50 -0
  14. data/spec/attributes_spec.rb +36 -0
  15. data/spec/fixtures/address.xml +9 -0
  16. data/spec/fixtures/ambigous_items.xml +22 -0
  17. data/spec/fixtures/analytics.xml +61 -0
  18. data/spec/fixtures/analytics_profile.xml +127 -0
  19. data/spec/fixtures/atom.xml +19 -0
  20. data/spec/fixtures/commit.xml +52 -0
  21. data/spec/fixtures/current_weather.xml +89 -0
  22. data/spec/fixtures/current_weather_missing_elements.xml +18 -0
  23. data/spec/fixtures/default_namespace_combi.xml +6 -0
  24. data/spec/fixtures/dictionary.xml +20 -0
  25. data/spec/fixtures/family_tree.xml +21 -0
  26. data/spec/fixtures/inagy.xml +85 -0
  27. data/spec/fixtures/lastfm.xml +355 -0
  28. data/spec/fixtures/multiple_namespaces.xml +170 -0
  29. data/spec/fixtures/multiple_primitives.xml +5 -0
  30. data/spec/fixtures/optional_attributes.xml +6 -0
  31. data/spec/fixtures/pita.xml +133 -0
  32. data/spec/fixtures/posts.xml +23 -0
  33. data/spec/fixtures/product_default_namespace.xml +18 -0
  34. data/spec/fixtures/product_no_namespace.xml +10 -0
  35. data/spec/fixtures/product_single_namespace.xml +10 -0
  36. data/spec/fixtures/quarters.xml +19 -0
  37. data/spec/fixtures/radar.xml +21 -0
  38. data/spec/fixtures/set_config_options.xml +3 -0
  39. data/spec/fixtures/statuses.xml +422 -0
  40. data/spec/fixtures/subclass_namespace.xml +50 -0
  41. data/spec/fixtures/wrapper.xml +11 -0
  42. data/spec/happymapper/attribute_spec.rb +12 -0
  43. data/spec/happymapper/element_spec.rb +9 -0
  44. data/spec/happymapper/item_spec.rb +115 -0
  45. data/spec/happymapper/text_node_spec.rb +9 -0
  46. data/spec/happymapper_parse_spec.rb +113 -0
  47. data/spec/happymapper_spec.rb +1116 -0
  48. data/spec/has_many_empty_array_spec.rb +43 -0
  49. data/spec/ignay_spec.rb +95 -0
  50. data/spec/inheritance_spec.rb +107 -0
  51. data/spec/mixed_namespaces_spec.rb +61 -0
  52. data/spec/parse_with_object_to_update_spec.rb +111 -0
  53. data/spec/spec_helper.rb +7 -0
  54. data/spec/to_xml_spec.rb +200 -0
  55. data/spec/to_xml_with_namespaces_spec.rb +231 -0
  56. data/spec/wilcard_tag_name_spec.rb +96 -0
  57. data/spec/wrap_spec.rb +82 -0
  58. data/spec/xpath_spec.rb +89 -0
  59. metadata +182 -0
@@ -0,0 +1,8 @@
1
+ module HappyMapper
2
+ class TextNode < Item
3
+
4
+ def find(node, namespace, xpath_options)
5
+ yield(node.children.detect{|c| c.text?})
6
+ end
7
+ end
8
+ end
@@ -0,0 +1,3 @@
1
+ module HappyMapper
2
+ VERSION = "0.5.9"
3
+ end
data/lib/xmlmapper.rb ADDED
@@ -0,0 +1 @@
1
+ require 'happymapper'
@@ -0,0 +1,50 @@
1
+ require 'spec_helper'
2
+
3
+ describe "Attribute Default Value" do
4
+
5
+ context "when given a default value" do
6
+
7
+ class Meal
8
+ include HappyMapper
9
+ tag 'meal'
10
+ attribute :type, String, :default => 'omnivore'
11
+ end
12
+
13
+ let(:subject) { Meal }
14
+ let(:default_meal_type) { 'omnivore' }
15
+
16
+ context "when no value has been specified" do
17
+ it "returns the default value" do
18
+ meal = subject.parse('<meal />')
19
+ expect(meal.type).to eq default_meal_type
20
+ end
21
+ end
22
+
23
+ context "when saving to xml" do
24
+
25
+ let(:expected_xml) { %{<?xml version="1.0"?>\n<meal/>\n} }
26
+
27
+ it "the default value is not included" do
28
+ meal = subject.new
29
+ expect(meal.to_xml).to eq expected_xml
30
+ end
31
+ end
32
+
33
+ context "when a new, non-nil value has been set" do
34
+ it "returns the new value" do
35
+ meal = subject.parse('<meal />')
36
+ meal.type = 'vegan'
37
+
38
+ expect(meal.type).to_not eq default_meal_type
39
+ end
40
+
41
+ let(:expected_xml) { %{<?xml version="1.0"?>\n<meal type="kosher"/>\n} }
42
+
43
+ it "saves the new value to the xml" do
44
+ meal = subject.new
45
+ meal.type = 'kosher'
46
+ expect(meal.to_xml).to eq expected_xml
47
+ end
48
+ end
49
+ end
50
+ end
@@ -0,0 +1,36 @@
1
+ require 'spec_helper'
2
+
3
+ describe "Attribute Method Conversion" do
4
+
5
+ let(:xml_document) do
6
+ %{<document>
7
+ <link data-src='http://cooking.com/roastbeef' type='recipe'>Roast Beef</link>
8
+ </document>}
9
+ end
10
+
11
+ module AttributeMethodConversion
12
+ class Document
13
+ include HappyMapper
14
+
15
+ has_many :link, String, :attributes => { :'data-src' => String, :type => String, :href => String }
16
+
17
+ end
18
+ end
19
+
20
+ let(:document) do
21
+ AttributeMethodConversion::Document.parse(xml_document,single: true)
22
+ end
23
+
24
+ it "link" do
25
+ expect(document.link).to eq ["Roast Beef"]
26
+ end
27
+
28
+ it "link.data_src" do
29
+ expect(document.link.first.data_src).to eq "http://cooking.com/roastbeef"
30
+ end
31
+
32
+ it "link.type" do
33
+ expect(document.link.first.type).to eq "recipe"
34
+ end
35
+
36
+ end
@@ -0,0 +1,9 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <address>
3
+ <street>Milchstrasse</street>
4
+ <housenumber>23</housenumber>
5
+ <postcode>26131</postcode>
6
+ <city>Oldenburg</city>
7
+ <country code="de">Germany</country>
8
+ <state>Lower Saxony</state>
9
+ </address>
@@ -0,0 +1,22 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <ambigous>
3
+ <my-items>
4
+ <item>
5
+ <name>My first item</name>
6
+ <item><name>My first internal item</name></item>
7
+ </item>
8
+ <item>
9
+ <name>My second item</name>
10
+ <item><name>My second internal item</name></item>
11
+ </item>
12
+ <item>
13
+ <name>My third item</name>
14
+ <item><name>My third internal item</name></item>
15
+ </item>
16
+ </my-items>
17
+ <others-items>
18
+ <item>
19
+ <name>Other item</name>
20
+ </item>
21
+ </others-items>
22
+ </ambigous>
@@ -0,0 +1,61 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <feed xmlns="http://www.w3.org/2005/Atom"
3
+ xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/"
4
+ xmlns:dxp="http://schemas.google.com/analytics/2009">
5
+ <id>http://www.google.com/analytics/feeds/accounts/nunemaker@gmail.com</id>
6
+ <updated>2009-04-22T23:21:23.000-07:00</updated>
7
+ <title type="text">Profile list for nunemaker@gmail.com</title>
8
+ <link rel="self" type="application/atom+xml"
9
+ href="http://www.google.com/analytics/feeds/accounts/default"/>
10
+ <author>
11
+ <name>Google Analytics</name>
12
+ </author>
13
+ <generator version="1.0">Google Analytics</generator>
14
+ <openSearch:totalResults>4</openSearch:totalResults>
15
+ <openSearch:startIndex>1</openSearch:startIndex>
16
+ <openSearch:itemsPerPage>4</openSearch:itemsPerPage>
17
+ <entry>
18
+ <id>http://www.google.com/analytics/feeds/accounts/ga:47912</id>
19
+ <updated>2008-11-24T12:11:32.000-08:00</updated>
20
+ <title type="text">addictedtonew.com</title>
21
+ <link rel="alternate" type="text/html" href="http://www.google.com/analytics"/>
22
+ <dxp:tableId>ga:47912</dxp:tableId>
23
+ <dxp:property name="ga:accountId" value="85301"/>
24
+ <dxp:property name="ga:accountName" value="addictedtonew.com"/>
25
+ <dxp:property name="ga:profileId" value="47912"/>
26
+ <dxp:property name="ga:webPropertyId" value="UA-85301-1"/>
27
+ </entry>
28
+ <entry>
29
+ <id>http://www.google.com/analytics/feeds/accounts/ga:1897579</id>
30
+ <updated>2008-11-24T12:11:32.000-08:00</updated>
31
+ <title type="text">railstips.org</title>
32
+ <link rel="alternate" type="text/html" href="http://www.google.com/analytics"/>
33
+ <dxp:tableId>ga:1897579</dxp:tableId>
34
+ <dxp:property name="ga:accountId" value="85301"/>
35
+ <dxp:property name="ga:accountName" value="addictedtonew.com"/>
36
+ <dxp:property name="ga:profileId" value="1897579"/>
37
+ <dxp:property name="ga:webPropertyId" value="UA-85301-7"/>
38
+ </entry>
39
+ <entry>
40
+ <id>http://www.google.com/analytics/feeds/accounts/ga:17132454</id>
41
+ <updated>2009-04-22T23:21:23.000-07:00</updated>
42
+ <title type="text">johnnunemaker.com</title>
43
+ <link rel="alternate" type="text/html" href="http://www.google.com/analytics"/>
44
+ <dxp:tableId>ga:17132454</dxp:tableId>
45
+ <dxp:property name="ga:accountId" value="85301"/>
46
+ <dxp:property name="ga:accountName" value="addictedtonew.com"/>
47
+ <dxp:property name="ga:profileId" value="17132454"/>
48
+ <dxp:property name="ga:webPropertyId" value="UA-85301-25"/>
49
+ </entry>
50
+ <entry>
51
+ <id>http://www.google.com/analytics/feeds/accounts/ga:17132478</id>
52
+ <updated>2009-04-22T23:21:23.000-07:00</updated>
53
+ <title type="text">harmonyapp.com</title>
54
+ <link rel="alternate" type="text/html" href="http://www.google.com/analytics"/>
55
+ <dxp:tableId>ga:17132478</dxp:tableId>
56
+ <dxp:property name="ga:accountId" value="85301"/>
57
+ <dxp:property name="ga:accountName" value="addictedtonew.com"/>
58
+ <dxp:property name="ga:profileId" value="17132478"/>
59
+ <dxp:property name="ga:webPropertyId" value="UA-85301-26"/>
60
+ </entry>
61
+ </feed>
@@ -0,0 +1,127 @@
1
+ <feed xmlns='http://www.w3.org/2005/Atom' xmlns:dxp='http://schemas.google.com/analytics/2009' xmlns:openSearch='http://a9.com/-/spec/opensearch/1.1/' xmlns:gd='http://schemas.google.com/g/2005' gd:etag='W/&quot;CU4CSXo_cCp7I2A9Wx9RGU0.&quot;' gd:kind='analytics#accounts'>
2
+ <id>http://www.google.com/analytics/feeds/accounts/someuser@gmail.com</id>
3
+ <updated>2010-12-20T19:59:28.448-08:00</updated>
4
+ <title>Profile list for someuser@gmail.com</title>
5
+ <link rel='self' type='application/atom+xml' href='https://www.google.com/analytics/feeds/accounts/default'/>
6
+ <author>
7
+ <name>Google Analytics</name>
8
+ </author>
9
+ <generator version='1.0'>Google Analytics</generator>
10
+ <openSearch:totalResults>9</openSearch:totalResults>
11
+ <openSearch:startIndex>1</openSearch:startIndex>
12
+ <openSearch:itemsPerPage>9</openSearch:itemsPerPage>
13
+ <dxp:segment id='gaid::-1' name='All Visits'>
14
+ <dxp:definition> </dxp:definition>
15
+ </dxp:segment>
16
+ <dxp:segment id='gaid::-2' name='New Visitors'>
17
+ <dxp:definition>ga:visitorType==New Visitor</dxp:definition>
18
+ </dxp:segment>
19
+ <dxp:segment id='gaid::-3' name='Returning Visitors'>
20
+ <dxp:definition>ga:visitorType==Returning Visitor</dxp:definition>
21
+ </dxp:segment>
22
+ <dxp:segment id='gaid::-4' name='Paid Search Traffic'>
23
+ <dxp:definition>ga:medium==cpa,ga:medium==cpc,ga:medium==cpm,ga:medium==cpp,ga:medium==cpv,ga:medium==ppc</dxp:definition>
24
+ </dxp:segment>
25
+ <dxp:segment id='gaid::-5' name='Non-paid Search Traffic'>
26
+ <dxp:definition>ga:medium==organic</dxp:definition>
27
+ </dxp:segment>
28
+ <dxp:segment id='gaid::-6' name='Search Traffic'>
29
+ <dxp:definition>ga:medium==cpa,ga:medium==cpc,ga:medium==cpm,ga:medium==cpp,ga:medium==cpv,ga:medium==organic,ga:medium==ppc</dxp:definition>
30
+ </dxp:segment>
31
+ <dxp:segment id='gaid::-7' name='Direct Traffic'>
32
+ <dxp:definition>ga:medium==(none)</dxp:definition>
33
+ </dxp:segment>
34
+ <dxp:segment id='gaid::-8' name='Referral Traffic'>
35
+ <dxp:definition>ga:medium==referral</dxp:definition>
36
+ </dxp:segment>
37
+ <dxp:segment id='gaid::-9' name='Visits with Conversions'>
38
+ <dxp:definition>ga:goalCompletionsAll&gt;0</dxp:definition>
39
+ </dxp:segment>
40
+ <dxp:segment id='gaid::-10' name='Visits with Transactions'>
41
+ <dxp:definition>ga:transactions&gt;0</dxp:definition>
42
+ </dxp:segment>
43
+ <dxp:segment id='gaid::-11' name='Mobile Traffic'>
44
+ <dxp:definition>ga:isMobile==Yes</dxp:definition>
45
+ </dxp:segment>
46
+ <dxp:segment id='gaid::-12' name='Non-bounce Visits'>
47
+ <dxp:definition>ga:bounces==0</dxp:definition>
48
+ </dxp:segment>
49
+ <entry gd:etag='W/&quot;CkENQXs9fip7I2A9Wx5SE0w.&quot;' gd:kind='analytics#account'>
50
+ <id>http://www.google.com/analytics/feeds/accounts/ga:123456</id>
51
+ <updated>2010-08-08T16:38:10.566-07:00</updated>
52
+ <title>www.homedepot.com</title>
53
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
54
+ <dxp:property name='ga:accountId' value='254087'/>
55
+ <dxp:property name='ga:accountName' value='www.homechefdepot.com'/>
56
+ <dxp:property name='ga:profileId' value='123456'/>
57
+ <dxp:property name='ga:webPropertyId' value='UA-254087-1'/>
58
+ <dxp:property name='ga:currency' value='USD'/>
59
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
60
+ <dxp:tableId>ga:123456</dxp:tableId>
61
+ </entry>
62
+ <entry gd:etag='W/&quot;C0YESXcyfyp7I2A9Wx9SFkU.&quot;' gd:kind='analytics#account'>
63
+ <id>http://www.google.com/analytics/feeds/accounts/ga:8575980</id>
64
+ <updated>2010-12-06T16:18:28.997-08:00</updated>
65
+ <title>www.pda.org</title>
66
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
67
+ <dxp:property name='ga:accountId' value='4277553'/>
68
+ <dxp:property name='ga:accountName' value='www.pdma.org'/>
69
+ <dxp:property name='ga:profileId' value='8575980'/>
70
+ <dxp:property name='ga:webPropertyId' value='UA-4277553-1'/>
71
+ <dxp:property name='ga:currency' value='USD'/>
72
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
73
+ <dxp:tableId>ga:8575980</dxp:tableId>
74
+ </entry>
75
+ <entry gd:etag='W/&quot;CU4CSXo_cCp7I2A9Wx9RGU0.&quot;' gd:kind='analytics#account'>
76
+ <id>http://www.google.com/analytics/feeds/accounts/ga:25620226</id>
77
+ <updated>2010-12-20T19:59:28.448-08:00</updated>
78
+ <title>business.com</title>
79
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
80
+ <dxp:property name='ga:accountId' value='12312214'/>
81
+ <dxp:property name='ga:accountName' value='business.com'/>
82
+ <dxp:property name='ga:profileId' value='25620226'/>
83
+ <dxp:property name='ga:webPropertyId' value='UA-12312214-1'/>
84
+ <dxp:property name='ga:currency' value='USD'/>
85
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
86
+ <dxp:tableId>ga:25620226</dxp:tableId>
87
+ </entry>
88
+ <entry gd:etag='W/&quot;CU4CSX0yfCp7I2A9Wx9RGU0.&quot;' gd:kind='analytics#account'>
89
+ <id>http://www.google.com/analytics/feeds/accounts/ga:12123131</id>
90
+ <updated>2010-12-20T19:59:28.394-08:00</updated>
91
+ <title>blog.com</title>
92
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
93
+ <dxp:property name='ga:accountId' value='12312214'/>
94
+ <dxp:property name='ga:accountName' value='business.com'/>
95
+ <dxp:property name='ga:profileId' value='12123131'/>
96
+ <dxp:property name='ga:webPropertyId' value='UA-12345678-1'/>
97
+ <dxp:property name='ga:currency' value='USD'/>
98
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
99
+ <dxp:tableId>ga:12123131</dxp:tableId>
100
+ </entry>
101
+ <entry gd:etag='W/&quot;DUMNQHk_fSp7I2A9Wx5bEE4.&quot;' gd:kind='analytics#account'>
102
+ <id>http://www.google.com/analytics/feeds/accounts/ga:37685582</id>
103
+ <updated>2010-10-25T13:11:31.745-07:00</updated>
104
+ <title>The Social</title>
105
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
106
+ <dxp:property name='ga:accountId' value='12312214'/>
107
+ <dxp:property name='ga:accountName' value='business.com'/>
108
+ <dxp:property name='ga:profileId' value='37685582'/>
109
+ <dxp:property name='ga:webPropertyId' value='UA-12312214-1'/>
110
+ <dxp:property name='ga:currency' value='USD'/>
111
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
112
+ <dxp:tableId>ga:37685582</dxp:tableId>
113
+ </entry>
114
+ <entry gd:etag='W/&quot;DE8HR3o4eCp7I2A9Wx5UF0w.&quot;' gd:kind='analytics#account'>
115
+ <id>http://www.google.com/analytics/feeds/accounts/ga:38132423</id>
116
+ <updated>2010-10-21T20:07:16.430-07:00</updated>
117
+ <title>Skyline</title>
118
+ <link rel='alternate' type='text/html' href='http://www.google.com/analytics'/>
119
+ <dxp:property name='ga:accountId' value='12312214'/>
120
+ <dxp:property name='ga:accountName' value='business.com'/>
121
+ <dxp:property name='ga:profileId' value='38132423'/>
122
+ <dxp:property name='ga:webPropertyId' value='UA-12312214-1'/>
123
+ <dxp:property name='ga:currency' value='USD'/>
124
+ <dxp:property name='ga:timezone' value='America/Los_Angeles'/>
125
+ <dxp:tableId>ga:38132423</dxp:tableId>
126
+ </entry>
127
+ </feed>
@@ -0,0 +1,19 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
3
+ <id>tag:www.example.com,2005:/tv_shows</id>
4
+ <link rel="alternate" type="text/html" href="http://www.example.com"/>
5
+ <link rel="self" type="application/atom+xml" href="http://www.example.com/tv_shows.atom"/>
6
+ <title>TV Shows</title>
7
+ <updated>2011-07-08T13:47:01Z</updated>
8
+ <entry>
9
+ <id>tag:www.example.com,2005:TvShow/17</id>
10
+ <published>2011-07-08T13:47:01Z</published>
11
+ <updated>2011-07-08T13:47:01Z</updated>
12
+ <link rel="alternate" type="text/html" href="http://www.example.com/sources/channel-twenty-seven/tv_shows/name-goes-here.atom"/>
13
+ <title>Name goes here</title>
14
+ <content type="html">Name goes here (0 episodes)</content>
15
+ <author>
16
+ <name>Source URL goes here</name>
17
+ </author>
18
+ </entry>
19
+ </feed>
@@ -0,0 +1,52 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <commit>
3
+ <removed type="array">
4
+ <removed>
5
+ <filename>commands.rb</filename>
6
+ </removed>
7
+ <removed>
8
+ <filename>helpers.rb</filename>
9
+ </removed>
10
+ </removed>
11
+ <added type="array">
12
+ <added>
13
+ <filename>commands/commands.rb</filename>
14
+ </added>
15
+ <added>
16
+ <filename>commands/helpers.rb</filename>
17
+ </added>
18
+ </added>
19
+ <message>move commands.rb and helpers.rb into commands/ dir</message>
20
+ <modified type="array">
21
+ <modified>
22
+ <diff>@@ -56,7 +56,7 @@ module GitHub
23
+ end
24
+
25
+ def load(file)
26
+ - file[0] == ?/ ? super : super(BasePath + "/#{file}")
27
+ + file[0] == ?/ ? super : super(BasePath + "/commands/#{file}")
28
+ end
29
+
30
+ def debug(*messages)</diff>
31
+ <filename>lib/github.rb</filename>
32
+ </modified>
33
+ </modified>
34
+ <parents type="array">
35
+ <parent>
36
+ <id>d462d2a2e60438ded3dd9e8e6593ca4146c5a0ba</id>
37
+ </parent>
38
+ </parents>
39
+ <url>http://github.com/defunkt/github-gem/commit/c26d4ce9807ecf57d3f9eefe19ae64e75bcaaa8b</url>
40
+ <author>
41
+ <name>Chris Wanstrath</name>
42
+ <email>chris@ozmm.org</email>
43
+ </author>
44
+ <id>c26d4ce9807ecf57d3f9eefe19ae64e75bcaaa8b</id>
45
+ <committed-date>2008-03-02T16:45:41-08:00</committed-date>
46
+ <authored-date>2008-03-02T16:45:41-08:00</authored-date>
47
+ <tree>28a1a1ca3e663d35ba8bf07d3f1781af71359b76</tree>
48
+ <committer>
49
+ <name>Chris Wanstrath</name>
50
+ <email>chris@ozmm.org</email>
51
+ </committer>
52
+ </commit>
@@ -0,0 +1,89 @@
1
+ <aws:weather xmlns:aws="http://www.aws.com/aws">
2
+ <aws:api version="2.0"/>
3
+ <aws:WebURL>http://weather.weatherbug.com/IN/Carmel-weather.html?ZCode=Z5546&amp;Units=0&amp;stat=MOCAR</aws:WebURL>
4
+ <aws:ob>
5
+ <aws:ob-date>
6
+ <aws:year number="2008"/>
7
+ <aws:month number="12" text="December" abbrv="Dec"/>
8
+ <aws:day number="30" text="Tuesday" abbrv="Tue"/>
9
+ <aws:hour number="4" hour-24="16"/>
10
+ <aws:minute number="18"/>
11
+ <aws:second number="01"/>
12
+ <aws:am-pm abbrv="PM"/>
13
+ <aws:time-zone offset="-5" text="Eastern Standard Time" abbrv="EST"/>
14
+ </aws:ob-date>
15
+ <aws:requested-station-id>mocar</aws:requested-station-id>
16
+ <aws:station-id>MOCAR</aws:station-id>
17
+ <aws:station>Mohawk Trail ES</aws:station>
18
+ <aws:city-state zipcode="46033">Carmel, IN</aws:city-state>
19
+ <aws:country>USA</aws:country>
20
+ <aws:latitude>39.9711111111111</aws:latitude>
21
+ <aws:longitude>-86.0938888888889</aws:longitude>
22
+ <aws:site-url>http://www1.ccs.k12.in.us/mte/home</aws:site-url>
23
+ <aws:aux-temp units="&amp;deg;F">74</aws:aux-temp>
24
+ <aws:aux-temp-rate units="&amp;deg;F">+0.0</aws:aux-temp-rate>
25
+ <aws:current-condition icon="http://deskwx.weatherbug.com/images/Forecast/icons/cond007.gif">Sunny</aws:current-condition>
26
+ <aws:dew-point units="&amp;deg;F">35</aws:dew-point>
27
+ <aws:elevation units="ft">817</aws:elevation>
28
+ <aws:feels-like units="&amp;deg;F">51</aws:feels-like>
29
+ <aws:gust-time>
30
+ <aws:year number="0001"/>
31
+ <aws:month number="1" text="January" abbrv="Jan"/>
32
+ <aws:day number="1" text="Monday" abbrv="Mon"/>
33
+ <aws:hour number="12" hour-24="00"/>
34
+ <aws:minute number="00"/>
35
+ <aws:second number="00"/>
36
+ <aws:am-pm abbrv="AM"/>
37
+ <aws:time-zone offset="-5" text="Eastern Standard Time" abbrv="EST"/>
38
+ </aws:gust-time>
39
+ <aws:gust-direction>W</aws:gust-direction>
40
+ <aws:gust-speed units="mph">25</aws:gust-speed>
41
+ <aws:humidity units="%">53</aws:humidity>
42
+ <aws:humidity-high units="%">100.0</aws:humidity-high>
43
+ <aws:humidity-low units="%">42.5</aws:humidity-low>
44
+ <aws:humidity-rate>-5.0</aws:humidity-rate>
45
+ <aws:indoor-temp units="&amp;deg;F">75</aws:indoor-temp>
46
+ <aws:indoor-temp-rate units="&amp;deg;F">+0.0</aws:indoor-temp-rate>
47
+ <aws:light>28</aws:light>
48
+ <aws:light-rate>-1.5</aws:light-rate>
49
+ <aws:moon-phase moon-phase-img="http://api.wxbug.net/images/moonphase/mphase02.gif">-10</aws:moon-phase>
50
+ <aws:pressure units="&quot;">29.71</aws:pressure>
51
+ <aws:pressure-high units="&quot;">30.18</aws:pressure-high>
52
+ <aws:pressure-low units="&quot;">29.71</aws:pressure-low>
53
+ <aws:pressure-rate units="&quot;/h">-0.04</aws:pressure-rate>
54
+ <aws:rain-month units="&quot;">6.64</aws:rain-month>
55
+ <aws:rain-rate units="&quot;/h">0.00</aws:rain-rate>
56
+ <aws:rain-rate-max units="&quot;/h">0.00</aws:rain-rate-max>
57
+ <aws:rain-today units="&quot;">0.00</aws:rain-today>
58
+ <aws:rain-year units="&quot;">53.83</aws:rain-year>
59
+ <aws:temp units="&amp;deg;F">51.8</aws:temp>
60
+ <aws:temp-high units="&amp;deg;F">52</aws:temp-high>
61
+ <aws:temp-low units="&amp;deg;F">29</aws:temp-low>
62
+ <aws:temp-rate units="&amp;deg;F/h">+2.5</aws:temp-rate>
63
+ <aws:sunrise>
64
+ <aws:year number="2008"/>
65
+ <aws:month number="12" text="December" abbrv="Dec"/>
66
+ <aws:day number="30" text="Tuesday" abbrv="Tue"/>
67
+ <aws:hour number="8" hour-24="08"/>
68
+ <aws:minute number="06"/>
69
+ <aws:second number="02"/>
70
+ <aws:am-pm abbrv="AM"/>
71
+ <aws:time-zone offset="-5" text="Eastern Standard Time" abbrv="EST"/>
72
+ </aws:sunrise>
73
+ <aws:sunset>
74
+ <aws:year number="2008"/>
75
+ <aws:month number="12" text="December" abbrv="Dec"/>
76
+ <aws:day number="30" text="Tuesday" abbrv="Tue"/>
77
+ <aws:hour number="5" hour-24="17"/>
78
+ <aws:minute number="28"/>
79
+ <aws:second number="53"/>
80
+ <aws:am-pm abbrv="PM"/>
81
+ <aws:time-zone offset="-5" text="Eastern Standard Time" abbrv="EST"/>
82
+ </aws:sunset>
83
+ <aws:wet-bulb units="&amp;deg;F">44.24</aws:wet-bulb>
84
+ <aws:wind-speed units="mph">4</aws:wind-speed>
85
+ <aws:wind-speed-avg units="mph">7</aws:wind-speed-avg>
86
+ <aws:wind-direction>SSW</aws:wind-direction>
87
+ <aws:wind-direction-avg>SW</aws:wind-direction-avg>
88
+ </aws:ob>
89
+ </aws:weather>