Class: CommonCartridge::Elements::Resources::Dependency

Inherits:
Object
  • Object
show all
Includes:
SAXMachine
Defined in:
lib/common_cartridge/elements/resources.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#contentsObject



39
40
41
# File 'lib/common_cartridge/elements/resources.rb', line 39

def contents
  @contents ||= []
end

Instance Method Details

#points_possibleObject



49
50
51
52
53
# File 'lib/common_cartridge/elements/resources.rb', line 49

def points_possible
  if c = contents.detect { |content| !content.points_possible.to_s.empty? }
    return c.points_possible
  end
end

#titleObject



43
44
45
46
47
# File 'lib/common_cartridge/elements/resources.rb', line 43

def title
  if c = contents.detect { |content| !content.title.to_s.empty? }
    return c.title
  end
end