Class: Faun::SectionWithMeta
Instance Attribute Summary collapse
-
#meta ⇒ Object
readonly
Returns the value of attribute meta.
Attributes inherited from Section
Instance Method Summary collapse
-
#initialize(id, name, path, type) ⇒ SectionWithMeta
constructor
A new instance of SectionWithMeta.
Methods inherited from Section
#each, #each_key, #each_value, #to_json
Constructor Details
#initialize(id, name, path, type) ⇒ SectionWithMeta
Returns a new instance of SectionWithMeta.
54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/faun.rb', line 54 def initialize(id, name, path, type) super(id, name, path, type) Async do begin File.open(File.join(path, "meta.yaml"), "r:UTF-8") do |file| generic = Async::IO::Stream.new(file) = YAML.load(generic.read) end rescue = {} end end.wait end |
Instance Attribute Details
#meta ⇒ Object (readonly)
Returns the value of attribute meta.
52 53 54 |
# File 'lib/faun.rb', line 52 def end |