Sha256: 4fc7fd829664b13185ad9265869df218bc8e818e30305034dec560981744d86b
Contents?: true
Size: 553 Bytes
Versions: 5
Compression:
Stored size: 553 Bytes
Contents
require 'riak/link' module Ripple module Document # A Link that is tied to a particular document and tag. # The key is fetched from the document lazily when needed. class Link < Riak::Link attr_reader :document private :document def initialize(document, tag) @document = document super(document.class.bucket_name, nil, tag) end def key document.key end def hash document.hash end end def to_link(tag) Link.new(self, tag) end end end
Version data entries
5 entries across 5 versions & 4 rubygems