Class: SakaiInfo::MissingSite

Inherits:
Site show all
Defined in:
lib/sakai-info/site.rb

Instance Attribute Summary

Attributes inherited from Site

#dbrow, #title, #type

Attributes inherited from SakaiObject

#id

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Site

#announcement_channel, #announcement_count, #announcements, #announcements_serialization, #assignment_count, #assignments, #assignments_serialization, #attachment_storage, #calendar, #calendar_event_count, #calendar_events_serialization, count, count_by_property, count_by_type, count_by_user_id, #disk_serialization, #disk_unformatted_serialization, #disk_usage_csv, #dropbox_storage, find!, find_all, find_all_ids, find_all_non_workspace_ids, find_all_workspace_ids, find_by_title, find_by_type, find_ids_by_property, find_ids_by_semester, find_ids_by_title, find_ids_by_type, #forum_count, #forums, #forums_serialization, #gradebook, #gradebook_serialization, #group_count, #groups, #groups_serialization, #join_role, #joinable?, #melete_storage, #membership, #page_count, #pages, #pages_serialization, #pending_quiz_count, #pending_quizzes, #properties, #published?, #published_quiz_count, #published_quizzes, query_by_title, query_by_type, #quizzes_serialization, #realm, #realm_serialization, #resource_storage, #total_disk_usage, #user_count, #users_serialization

Methods included from ModProps

included

Methods inherited from SakaiObject

#dbrow_only_serialization, #dbrow_serialization, descendants, #object_type_serialization, #serialize, #shell_serialization, #to_csv, #to_json, #to_yaml

Constructor Details

#initialize(id) ⇒ MissingSite

Returns a new instance of MissingSite.



473
474
475
476
477
# File 'lib/sakai-info/site.rb', line 473

def initialize(id)
  @dbrow = {}

  @id = id
end

Class Method Details

.all_serializationsObject



495
496
497
498
499
# File 'lib/sakai-info/site.rb', line 495

def self.all_serializations
  [
   :default,
  ]
end

.clear_cacheObject



468
469
470
# File 'lib/sakai-info/site.rb', line 468

def self.clear_cache
  @@cache = {}
end

.find(id) ⇒ Object



479
480
481
# File 'lib/sakai-info/site.rb', line 479

def self.find(id)
  @@cache[id] ||= MissingSite.new(id)
end

Instance Method Details

#default_serializationObject



483
484
485
486
487
# File 'lib/sakai-info/site.rb', line 483

def default_serialization
  {
    "id" => "MISSING SITE: #{self.id}",
  }
end

#summary_serializationObject



489
490
491
492
493
# File 'lib/sakai-info/site.rb', line 489

def summary_serialization
  {
    "id" => "MISSING SITE: #{self.id}",
  }
end