Module: CommonCartridge

Defined in:
lib/common_cartridge.rb,
lib/common_cartridge/package.rb,
lib/common_cartridge/version.rb,
lib/common_cartridge/elements/lom.rb,
lib/common_cartridge/parsers/files.rb,
lib/common_cartridge/parsers/items.rb,
lib/common_cartridge/parsers/parser.rb,
lib/common_cartridge/parsers/outcomes.rb,
lib/common_cartridge/elements/manifest.rb,
lib/common_cartridge/elements/metadata.rb,
lib/common_cartridge/elements/outcomes.rb,
lib/common_cartridge/parsers/questions.rb,
lib/common_cartridge/elements/resources.rb,
lib/common_cartridge/parsers/dependencies.rb,
lib/common_cartridge/elements/organizations.rb,
lib/common_cartridge/elements/resources/page.rb,
lib/common_cartridge/elements/resources/topic.rb,
lib/common_cartridge/elements/outcomes/outcome.rb,
lib/common_cartridge/elements/resources/web_link.rb,
lib/common_cartridge/elements/resources/assessment.rb,
lib/common_cartridge/elements/resources/assignment.rb,
lib/common_cartridge/elements/outcomes/outcome_root.rb,
lib/common_cartridge/elements/resources/attachments.rb,
lib/common_cartridge/elements/outcomes/outcome_group.rb,
lib/common_cartridge/elements/resources/basic_lti_link.rb

Defined Under Namespace

Modules: Elements, Parsers Classes: Config, Package

Constant Summary collapse

VERSION =
'1.0.8'.freeze

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configObject

Returns the value of attribute config.



14
15
16
# File 'lib/common_cartridge.rb', line 14

def config
  @config
end

Class Method Details

.configure {|config| ... } ⇒ Object

Yields:



17
18
19
20
# File 'lib/common_cartridge.rb', line 17

def self.configure
  self.config ||= Config.new
  yield(config)
end

.parse_from_zip(zipfile) ⇒ Object



4
5
6
7
8
# File 'lib/common_cartridge.rb', line 4

def self.parse_from_zip(zipfile)
  parser = Parsers::Parser.new(zipfile)
  package = parser.parse
  package
end