module TivoHMO::API::Container

Represents the tivo concept of a Container (i.e. a directory that contains files or other containers)

Attributes

presorted[RW]
uuid[RW]

Public Class Methods

new(identifier) click to toggle source
Calls superclass method TivoHMO::API::Node::new
# File lib/tivohmo/api/container.rb, line 17
def initialize(identifier)
  super(identifier)
  self.uuid = SecureRandom.uuid
  self.presorted = false

  self.content_type = "x-tivo-container/tivo-videos"
  self.source_format = "x-tivo-container/folder"
end

Public Instance Methods

child_count() click to toggle source
# File lib/tivohmo/api/container.rb, line 32
def child_count
  children.size
end
refresh() click to toggle source
# File lib/tivohmo/api/container.rb, line 26
def refresh
  synchronize do
    self.children.clear
  end
end