Class: OKF::Bundle::Entry

Inherits:
Object
  • Object
show all
Defined in:
lib/okf/bundle.rb

Overview

Raw text of one markdown file. error is set only for unparseable entries (the ParseError message), nil for reserved files.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path:, content:, error: nil) ⇒ Entry

Returns a new instance of Entry.



26
27
28
29
30
# File 'lib/okf/bundle.rb', line 26

def initialize(path:, content:, error: nil)
  @path = path
  @content = content
  @error = error
end

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content.



24
25
26
# File 'lib/okf/bundle.rb', line 24

def content
  @content
end

#errorObject (readonly)

Returns the value of attribute error.



24
25
26
# File 'lib/okf/bundle.rb', line 24

def error
  @error
end

#pathObject (readonly)

Returns the value of attribute path.



24
25
26
# File 'lib/okf/bundle.rb', line 24

def path
  @path
end