class Orchestrate::Application::RefTable
Public Class Methods
disable()
click to toggle source
# File lib/orchestrate_application/ref_table.rb, line 24 def self.disable puts "DISABLE REF TABLE" @@is_enabled = false end
enable(name = nil)
click to toggle source
# File lib/orchestrate_application/ref_table.rb, line 14 def self.enable(name = nil) puts "ENABLE REF TABLE" @@is_enabled = true @@collection_name = name unless name.blank? Orchestrate::Application::Schema.instance.define_collection( :name => @@collection_name, :properties => [ :xcollection, :xkey, :timestamp, :xref] ) end
enabled?()
click to toggle source
# File lib/orchestrate_application/ref_table.rb, line 29 def self.enabled? @@is_enabled == true end
get_collection_name()
click to toggle source
# File lib/orchestrate_application/ref_table.rb, line 33 def self.get_collection_name @@collection_name end
new(params={})
click to toggle source
Calls superclass method
Orchestrate::Application::Record::new
# File lib/orchestrate_application/ref_table.rb, line 8 def initialize(params={}) return unless @@is_enabled == true params[:define_collection_name] = @@collection_name super params end