Sha256: 554f4902a2eb65c8855dc724718c65496b53c9e417bae5d6a832401a26473cf0

Contents?: true

Size: 636 Bytes

Versions: 21

Compression:

Stored size: 636 Bytes

Contents

module RailsConnector

class ContentCache < CmsBaseModel
  self.key_prefix = "cc"

  property :revision_id
  property :transferring_to

  # returns the revision that is represented by this content cache.
  # returns nil if the revision cannot be found.
  def revision
    @revision ||= Revision.find_by_id(revision_id)
  end

  # returns the revision that this content cache is currently transferring to.
  # returns nil if no transfer is taking place or if the revision cannot be found.
  def transfer_target
    @transfer_target ||= transferring_to ? Revision.find_by_id(transferring_to) : nil
  end
end

end # module RailsConnector

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
infopark_cloud_connector-6.8.3.115.227021242 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.3.73.75172665 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.3.2.153416031 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.3.67.110847540 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.3.1.23895778 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.2.36.82613853 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.2.7.128454143 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.1.26.236500544 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.1 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.539.93842523 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.529.114081979 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.518.30999728 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.515.34928522 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.498.46559598 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.480.261594408 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.444.171626367 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.406.131718077 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.356.19698103 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.348.160665197 lib/rails_connector/content_cache.rb
infopark_cloud_connector-6.8.0.328.4a753fc lib/rails_connector/content_cache.rb