Class: SakaiInfo::PublishedQuizAccessControl
- Inherits:
-
QuizAccessControl
- Object
- SakaiObject
- QuizAccessControl
- SakaiInfo::PublishedQuizAccessControl
- Defined in:
- lib/sakai-info/quiz.rb
Instance Attribute Summary
Attributes inherited from QuizAccessControl
Attributes inherited from SakaiObject
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from QuizAccessControl
#authenticated?, #automatic_submission?, #default_serialization, #due_date, #feedback_date, #final_page_url, #initialize, #item_navigation, #item_numbering, #late_handling, #mark_for_review_allowed?, #password, #question_layout, #quiz_summary_serialization, #release_to, #retract_date, #score_date, #start_date, #submission_message, #submissions_allowed, #submissions_saved, #summary_serialization, #time_limit, #timed?, #unlimited_submissions?, #username
Methods inherited from SakaiObject
all_serializations, #dbrow_only_serialization, #dbrow_serialization, #default_serialization, descendants, #object_type_serialization, #serialize, #shell_serialization, #summary_serialization, #to_csv, #to_json, #to_yaml
Constructor Details
This class inherits a constructor from SakaiInfo::QuizAccessControl
Class Method Details
.clear_cache ⇒ Object
1330 1331 1332 |
# File 'lib/sakai-info/quiz.rb', line 1330 def self.clear_cache @@cache = {} end |
.find(id) ⇒ Object
1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 |
# File 'lib/sakai-info/quiz.rb', line 1335 def self.find(id) id = id.to_s if @@cache[id].nil? row = DB.connect[:sam_publishedaccesscontrol_t].where(:assessmentid => id.to_i).first if row.nil? raise ObjectNotFoundException.new(PublishedQuizAccessControl, id) end @@cache[id] = PublishedQuizAccessControl.new(row) end @@cache[id] end |
Instance Method Details
#quiz ⇒ Object
1348 1349 1350 |
# File 'lib/sakai-info/quiz.rb', line 1348 def quiz @quiz ||= PublishedQuiz.find(self.id) end |