Sha256: 89a597b718fd478caae6367bf01de626e80a26b547ba15c2eec57d241ec4e0bd

Contents?: true

Size: 436 Bytes

Versions: 7

Compression:

Stored size: 436 Bytes

Contents

module HaveAPI::Fs::Components
  class ListItem < Directory
    component :list_item
    
    def initialize(action, dir, data)
      super()

      @action = action
      @dir = dir
      @data = data
    end

    def contents
      @action.params.keys.map(&:to_s)
    end

    protected
    def new_child(name)
      [
          Parameter,
          @action,
          name,
          @dir,
          @data,
      ]
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
haveapi-fs-0.11.0 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.10.0 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.9.0 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.8.0 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.7.1 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.7.0 lib/haveapi/fs/components/list_item.rb
haveapi-fs-0.1.0 lib/haveapi/fs/components/list_item.rb