Index: ruby/trunk/lib/models/assumed_library_types.rb
===================================================================
--- ruby/trunk/lib/models/assumed_library_types.rb	(revision 122)
+++ ruby/trunk/lib/models/assumed_library_types.rb	(revision 123)
@@ -382,4 +382,11 @@
       end
     end # end of ISO8601_TIMEZONE
+
+    class ISO_8601_DURATION
+      
+      def initialize
+      end
+
+    end
   end # end of Assumed_Types
 end # end of OpenEHR
Index: ruby/trunk/lib/models/rm.rb
===================================================================
--- ruby/trunk/lib/models/rm.rb	(revision 122)
+++ ruby/trunk/lib/models/rm.rb	(revision 123)
@@ -10,4 +10,7 @@
 # OpenEHR::RM
 module OpenEHR
+
+  autoload :Assumed_Library_Types, "assumed_library_types.rb"
+
   module RM
     autoload :Demographic, "rm/demographic.rb"
@@ -34,3 +37,4 @@
     end
   end
+
 end
Index: ruby/trunk/lib/models/rm/data_structures/data_structure.rb
===================================================================
--- ruby/trunk/lib/models/rm/data_structures/data_structure.rb	(revision 122)
+++ ruby/trunk/lib/models/rm/data_structures/data_structure.rb	(revision 123)
@@ -1,6 +1,8 @@
 # rm::data_structures
 # class DATA_STRUCTURE
-module DataStructures
-  class DataStructure
+# http://www.openehr.org/uml/release-1.0.1/Browsable/_9_5_1_76d0249_1140447518205_872539_864Report.html
+# refs #59
+module Data_Structures
+  class Data_Structure 
     def as_hierarchy
       raise NotImplementError, "as_hirarchy must be implemented"
Index: ruby/trunk/lib/models/rm/data_types/quantity.rb
===================================================================
--- ruby/trunk/lib/models/rm/data_types/quantity.rb	(revision 122)
+++ ruby/trunk/lib/models/rm/data_types/quantity.rb	(revision 123)
@@ -12,12 +12,11 @@
           def initialize(normal_range=nil, other_reference_ranges=nil,
                          normal_status = nil)
-            other_reference_ranges_validity(other_reference_ranges)
-            @normal_range = normal_range
-            @other_reference_ranges = other_reference_ranges
-            @normal_status = normal_status
+            self.normal_range = normal_range
+            self.other_reference_ranges = other_reference_ranges
+            self.normal_status = normal_status
           end          
 
           def is_normal?
-            !normal_range.nil? or !normal_status.nil
+            !normal_range.nil? or !normal_status.nil?
           end
 
@@ -31,15 +30,19 @@
 
           def normal_range=(normal_range)
+            @normal_range = normal_range
           end
 
           def other_reference_ranges=(other_reference_ranges)
+            unless other_reference_ranges.nil? or !other_reference_ranges.is_empty?
+              raise ArgumentError, "Other reference ranges validity error"
+            end
+            
+            @other_reference_ranges = other_reference_ranges
           end
 
-          private
-          def other_reference_ranges_validity(other_reference_ranges)
-            if !other_reference_ranges.nil? or other_reference_ranges.is_empty?
-              raise ArgumentError, "Other reference ranges validity error"
-            end
+          def normal_status=(normal_status)
+            @normal_status = normal_status
           end
+
         end
 
Index: ruby/trunk/lib/models/rm/data_types/quantity/date_time.rb
===================================================================
--- ruby/trunk/lib/models/rm/data_types/quantity/date_time.rb	(revision 122)
+++ ruby/trunk/lib/models/rm/data_types/quantity/date_time.rb	(revision 123)
@@ -9,7 +9,9 @@
           class DV_Temporal < OpenEHR::RM::Data_Types::Quantity::DV_Absolute_Quantity
             attr_reader :value
+
             def initialize(value)
               self.value = value
             end
+
             def value=(value)
               if value.empty? or value.nil?
@@ -18,4 +20,5 @@
               @value = value
             end
+
             def diff(value)
               raise NotImplementedError, 'diff must be implemented'
@@ -24,4 +27,17 @@
 
           class DV_Date < DV_Temporal
+            include OpenEHR::Assumed_Library_Types::ISO8601_DATE_MODULE
+            def initialize
+              
+            end
+
+          end
+          
+          class DV_Time
+            def initialize
+            end
+          end
+
+          class DV_Date_Time
             def initialize
             end
Index: ruby/trunk/lib/models/tests/rm/test_data_types.rb
===================================================================
--- ruby/trunk/lib/models/tests/rm/test_data_types.rb	(revision 122)
+++ ruby/trunk/lib/models/tests/rm/test_data_types.rb	(revision 123)
@@ -160,7 +160,22 @@
 end
 
+class QuantityTest < Test::Unit::TestCase
+  def setup
+    assert_nothing_raised(Exception){
+      @dv_ordered = OpenEHR::RM::Data_Types::Quantity::DV_Ordered.new }
+  end
+  def test_init
+    assert_instance_of OpenEHR::RM::Data_Types::Quantity::DV_Ordered, @dv_ordered
+  end
+
+  def test_dv_ordered
+    assert !@dv_ordered.is_normal?
+  end
+end
+
 class QuantityDateTimeTest < Test::Unit::TestCase
   def setup
-    assert_nothing_raised(Exception){@dv_temporal = OpenEHR::RM::Data_Types::Quantity::Date_Time::DV_Temporal.new('2008')}
+    assert_nothing_raised(Exception){
+      @dv_temporal = OpenEHR::RM::Data_Types::Quantity::Date_Time::DV_Temporal.new('2008')}
   end
   def test_init
Index: ruby/trunk/lib/models/tests/test_assumed_library_types.rb
===================================================================
--- ruby/trunk/lib/models/tests/test_assumed_library_types.rb	(revision 122)
+++ ruby/trunk/lib/models/tests/test_assumed_library_types.rb	(revision 123)
@@ -265,4 +265,7 @@
     assert_equal 0.32, @iso8601_date_time.fractional_second
     assert_equal '+0900', @iso8601_date_time.timezone
+    assert_nothing_raised(Exception){
+      @iso8601_date_time.year = 2008 }
+    assert_equal 2008, @iso8601_date_time.year
   end
 
@@ -281,3 +284,7 @@
     assert_equal "Z-0430", @iso8601_timezone.as_string
   end
+
+  def test_iso8601_duration
+    
+  end
 end
Index: ruby/trunk/lib/models/tests/test_reference_model.rb
===================================================================
--- ruby/trunk/lib/models/tests/test_reference_model.rb	(revision 122)
+++ ruby/trunk/lib/models/tests/test_reference_model.rb	(revision 123)
@@ -4,6 +4,2 @@
 
 Test::Unit::AutoRunner.run(true, './tests/rm')
-
-
-
-
