<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -5,6 +5,15 @@ module RTunesU
     validates!  :polling_interval, [:never, :daily]
     validates!  :security_type,  [:none, 'Basic Authentication']
     
+    # an ExternalFeed must serialize in a specific order
+    def to_xml(xml_builder = Builder::XmlMarkup.new)
+      xml_builder.tag!('ExternalFeed') do
+        %w(URL OwnerEmail PollingInterval SecurityType SignatureType BasicAuthUsername BasicAuthPassword).each do |tag_name|
+          xml_builder.tag!(tag_name, self.edits[tag_name]) if self.edits[tag_name]
+        end
+      end
+    end
+    
     # As an entirely nested entity ExternalFeed instances don't have a parent handle. However, something 'truthy' needs
     # to be presnet for proper XML document genration.
     def parent_handle # :nodoc:</diff>
      <filename>lib/rtunesu/entities/external_feed.rb</filename>
    </modified>
    <modified>
      <diff>@@ -10,11 +10,30 @@ module RTunesU
       :shared    =&gt; &quot;Shared&quot;,
       :edit      =&gt; &quot;Edit&quot;
     }
+    TYPES = {
+      :feed =&gt; &quot;Feed&quot;
+    }
     composed_of :name, :group_type, :short_name, :allow_subscription, :explicit
     composed_of :aggregate_file_size, :readonly =&gt; true
     validates! :group_type, [:simple, :smart, :feed]
     has_a :external_feed
     has_n :permissions, :tracks, :shared_objects
     
+    # a Group must serialize in a specific order
+    def to_xml(xml_builder = Builder::XmlMarkup.new)
+      xml_builder.tag!('Group') do
+        %w(Name Handle GroupType Explicit).each do |tag_name|
+          xml_builder.tag!(tag_name, self.edits[tag_name]) if self.edits[tag_name]
+        end
+        
+        self.tracks.to_xml(xml_builder)
+        self.permissions.to_xml(xml_builder)
+        
+        %w(AllowSubscription).each do |tag_name|
+          xml_builder.tag!(tag_name, self.edits[tag_name]) if self.edits[tag_name]
+        end
+        self.external_feed.to_xml(xml_builder) if self.external_feed
+      end
+    end
   end
 end
\ No newline at end of file</diff>
      <filename>lib/rtunesu/entities/group.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>49b1bea8ea808e409e57b95ad46489c9dfb7e9fd</id>
    </parent>
  </parents>
  <author>
    <name>Trek Glowacki</name>
    <email>pietrekg@umich.edu</email>
  </author>
  <url>http://github.com/trek/rtunesu/commit/cb0976c9cf64ae902684fbba2c0859dfeb14fabe</url>
  <id>cb0976c9cf64ae902684fbba2c0859dfeb14fabe</id>
  <committed-date>2009-11-08T10:20:27-08:00</committed-date>
  <authored-date>2009-11-08T10:20:27-08:00</authored-date>
  <message>Group and ExternalFeed objects require specific serialization order. NOTE: this is retarded.</message>
  <tree>78150d1b527d6ded892651770b97b91aa2e7f419</tree>
  <committer>
    <name>Trek Glowacki</name>
    <email>pietrekg@umich.edu</email>
  </committer>
</commit>
