Class: ManifestYAML
- Inherits:
-
Object
- Object
- ManifestYAML
- Defined in:
- lib/parser/manifest_parser.rb
Instance Attribute Summary collapse
-
#contents ⇒ Object
readonly
Returns the value of attribute contents.
-
#manifest_file_namepath ⇒ Object
readonly
Returns the value of attribute manifest_file_namepath.
-
#pack_language ⇒ Object
readonly
Returns the value of attribute pack_language.
Instance Method Summary collapse
- #get_dependencies ⇒ Object
- #get_exclude_files ⇒ Object
-
#initialize(manifest_file_namepath) ⇒ ManifestYAML
constructor
A new instance of ManifestYAML.
Constructor Details
#initialize(manifest_file_namepath) ⇒ ManifestYAML
Returns a new instance of ManifestYAML.
42 43 44 45 |
# File 'lib/parser/manifest_parser.rb', line 42 def initialize(manifest_file_namepath) @contents = YAML.load_file(manifest_file_namepath) @pack_language = 'manifest.yml' end |
Instance Attribute Details
#contents ⇒ Object (readonly)
Returns the value of attribute contents.
40 41 42 |
# File 'lib/parser/manifest_parser.rb', line 40 def contents @contents end |
#manifest_file_namepath ⇒ Object (readonly)
Returns the value of attribute manifest_file_namepath.
40 41 42 |
# File 'lib/parser/manifest_parser.rb', line 40 def manifest_file_namepath @manifest_file_namepath end |
#pack_language ⇒ Object (readonly)
Returns the value of attribute pack_language.
40 41 42 |
# File 'lib/parser/manifest_parser.rb', line 40 def pack_language @pack_language end |
Instance Method Details
#get_dependencies ⇒ Object
47 48 49 50 51 52 53 |
# File 'lib/parser/manifest_parser.rb', line 47 def get_dependencies() if @contents['dependencies'] == nil return [] else return @contents['dependencies'] end end |
#get_exclude_files ⇒ Object
55 56 57 |
# File 'lib/parser/manifest_parser.rb', line 55 def get_exclude_files() @contents['exclude_files'] end |