Class: SublimeTextKit::Metadata::Serializers::Project
- Inherits:
-
Object
- Object
- SublimeTextKit::Metadata::Serializers::Project
- Defined in:
- lib/sublime_text_kit/metadata/serializers/project.rb
Overview
Serializes project metadata.
Instance Attribute Summary collapse
-
#pathway ⇒ Object
readonly
Returns the value of attribute pathway.
Instance Method Summary collapse
-
#initialize(pathway) ⇒ Project
constructor
A new instance of Project.
- #to_h ⇒ Object
Constructor Details
#initialize(pathway) ⇒ Project
Returns a new instance of Project.
10 11 12 |
# File 'lib/sublime_text_kit/metadata/serializers/project.rb', line 10 def initialize pathway @pathway = pathway end |
Instance Attribute Details
#pathway ⇒ Object (readonly)
Returns the value of attribute pathway.
8 9 10 |
# File 'lib/sublime_text_kit/metadata/serializers/project.rb', line 8 def pathway @pathway end |
Instance Method Details
#to_h ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/sublime_text_kit/metadata/serializers/project.rb', line 14 def to_h { folders: [ {path: pathway.project_dir.to_s} ] } end |