Class: Folder
Overview
basic folder class, for parsing bookmarks
Instance Method Summary collapse
- #each ⇒ Object
-
#initialize(title = '/', json) ⇒ Folder
constructor
A new instance of Folder.
- #json ⇒ Object
- #title ⇒ Object
Constructor Details
#initialize(title = '/', json) ⇒ Folder
Returns a new instance of Folder.
5 6 7 8 |
# File 'lib/folder.rb', line 5 def initialize(title='/', json) @title = title.gsub(/[: ,'"]/, '-').downcase @json = json end |
Instance Method Details
#each ⇒ Object
18 19 20 |
# File 'lib/folder.rb', line 18 def each @json.each end |
#json ⇒ Object
14 15 16 |
# File 'lib/folder.rb', line 14 def json @json end |
#title ⇒ Object
10 11 12 |
# File 'lib/folder.rb', line 10 def title @title end |