deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lut...@apache.org
Subject [11/15] git commit: CIMI::Model::Schema::Ref: do not support looking up the referenced object
Date Thu, 14 Mar 2013 18:19:03 GMT
CIMI::Model::Schema::Ref: do not support looking up the referenced object

This now depends on service objects and can therefore not be used from models


Project: http://git-wip-us.apache.org/repos/asf/deltacloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltacloud/commit/66e0faea
Tree: http://git-wip-us.apache.org/repos/asf/deltacloud/tree/66e0faea
Diff: http://git-wip-us.apache.org/repos/asf/deltacloud/diff/66e0faea

Branch: refs/heads/master
Commit: 66e0faea4a2623787c06ce9b8661c929c93e0744
Parents: 8901805
Author: David Lutterkort <lutter@redhat.com>
Authored: Tue Mar 5 17:03:04 2013 -0800
Committer: David Lutterkort <lutter@redhat.com>
Committed: Wed Mar 13 17:28:13 2013 -0700

----------------------------------------------------------------------
 server/lib/cimi/models/schema.rb |   14 --------------
 1 files changed, 0 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/66e0faea/server/lib/cimi/models/schema.rb
----------------------------------------------------------------------
diff --git a/server/lib/cimi/models/schema.rb b/server/lib/cimi/models/schema.rb
index b6651a7..5a2049b 100644
--- a/server/lib/cimi/models/schema.rb
+++ b/server/lib/cimi/models/schema.rb
@@ -191,20 +191,6 @@ class CIMI::Model::Schema
       else
         @klass = Class.new(opts[:class]) do |m|
           scalar :href
-
-          def ref_id(ctx)
-            # FIXME: We should use ctx's routes to split
-            # out the :id
-            href.split('/').last
-          end
-
-          def find(ctx)
-            klass.find(ref_id(ctx), ctx)
-          end
-
-          def klass
-            self.class.superclass
-          end
         end
         CIMI::Model::const_set(refname, @klass)
       end


Mime
View raw message