Class: Yamo::Singleton
- Includes:
- Singleton
- Defined in:
- lib/yamo/singleton.rb
Instance Attribute Summary
Attributes inherited from Object
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ Singleton
constructor
A new instance of Singleton.
Methods inherited from Object
create_accessors, load_and_validate_file, load_and_validate_source, schema, validate_data, validator
Constructor Details
#initialize ⇒ Singleton
Returns a new instance of Singleton.
16 17 18 |
# File 'lib/yamo/singleton.rb', line 16 def initialize @data = @@data end |
Class Method Details
.object(file) ⇒ Object
11 12 13 14 |
# File 'lib/yamo/singleton.rb', line 11 def self.object(file) @@data = self.load_and_validate_file(file) @object = file end |