This commit is contained in:
20
lib/notare/nodes/list.rb
Normal file
20
lib/notare/nodes/list.rb
Normal file
@@ -0,0 +1,20 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module Notare
|
||||
module Nodes
|
||||
class List < Base
|
||||
attr_reader :items, :type, :num_id
|
||||
|
||||
def initialize(type:, num_id:)
|
||||
super()
|
||||
@type = type
|
||||
@num_id = num_id
|
||||
@items = []
|
||||
end
|
||||
|
||||
def add_item(item)
|
||||
@items << item
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user