Class: Qti::Models::Manifest

Inherits:
Base
  • Object
show all
Includes:
ResourceGroup, XPathHelpers
Defined in:
lib/qti/models/manifest.rb

Constant Summary

Constants included from ResourceGroup

ResourceGroup::ASSESSMENT_CLASSES, ResourceGroup::EMBEDDED_NON_ASSESSMENT_ID, ResourceGroup::EMBEDDED_QTI_TYPES, ResourceGroup::RESOURCE_QTI_TYPES

Instance Attribute Summary

Attributes inherited from Base

#doc, #manifest, #package_root, #path, #resource

Instance Method Summary collapse

Methods included from XPathHelpers

#rtype_predicate, #xpath_endswith, #xpath_resource

Methods included from ResourceGroup

#assessment_identifiers, #asset_resource_for, #asset_resource_for_canvas, #asset_resource_for_ims, #identifier_list, #item_resources_v2, #question_bank_identifiers, #resource_for, #resource_node, #resources

Methods inherited from Base

#css_with_single_check, from_path!, #initialize, #parse_html, #parse_xml, #preprocess_xml_doc, #raise_unsupported, #remap_href_path, #sanitize_content!, #xpath_with_single_check

Constructor Details

This class inherits a constructor from Qti::Models::Base

Instance Method Details

#assessment_test(resource_id = nil) ⇒ Object



13
14
15
16
17
18
# File 'lib/qti/models/manifest.rb', line 13

def assessment_test(resource_id = nil)
  resource_id ||= assessment_identifiers.first
  test = assessment_from_identifier(resource_id)
  test.manifest = self
  test
end