Module: SitePrism::DSL::Builder Private

Defined in:
lib/site_prism/dsl/builder.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

SitePrism::DSL::Builder

The Building logic - Initially coming from ‘.build`

This will take a request to build from a DSL invocation such as `element` and generate a series of
helper methods and waiters. It will also generate the correct classes for `SitePrism::Section` objects

Whilst doing all of this, it will also build up a "map" of objects in memory which can be used for
future interrogation. There are 2 ways of this being stored currently (Default as a hash, Legacy as an array)

Instance Method Summary collapse

Instance Method Details

#mapped_itemsHash

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Return a list of all mapped items on a SitePrism class instance (Page or Section)

Returns:

  • (Hash)


20
21
22
# File 'lib/site_prism/dsl/builder.rb', line 20

def mapped_items
  @mapped_items ||= { element: [], elements: [], section: [], sections: [], iframe: [] }
end