You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by mf...@redhat.com on 2013/03/01 14:32:26 UTC

[PATCH core 6/9] CIMI: Added Service::Base#parse method

From: Michal Fojtik <mf...@redhat.com>

Make possible to call .parse on Service models from
Rabbit collections.

Signed-off-by: Michal fojtik <mf...@redhat.com>
---
 server/lib/cimi/service/base.rb | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/server/lib/cimi/service/base.rb b/server/lib/cimi/service/base.rb
index 9f2c765..8fbf256 100644
--- a/server/lib/cimi/service/base.rb
+++ b/server/lib/cimi/service/base.rb
@@ -50,6 +50,11 @@ module CIMI::Service
           define_method(:"#{name}=") { |newval| self[name] = newval }
         end
       end
+
+      def parse(text, content_type)
+        model_class.parse(text, content_type)
+      end
+
     end
 
     def initialize(context, opts)
-- 
1.8.1.2