Class: Geoblacklight::Configuration::LayerConfig

Inherits:
Object
  • Object
show all
Includes:
ActiveModel::Attributes, ActiveModel::Model
Defined in:
lib/geoblacklight/configuration/layer_config.rb

Overview

Configuration for Leaflet map layer styles.

Instance Method Summary collapse

Instance Method Details

#[](key) ⇒ Object

Supports Hash-like access for backward compatibility

Parameters:

  • key (Symbol, String)


17
18
19
# File 'lib/geoblacklight/configuration/layer_config.rb', line 17

def [](key)
  respond_to?(key) ? send(key) : nil
end

#to_hHash

Returns the attributes as a symbolized hash

Returns:

  • (Hash)


23
24
25
# File 'lib/geoblacklight/configuration/layer_config.rb', line 23

def to_h
  attributes.symbolize_keys
end