Class: Etl::Integrations::Protocol::ProtocolModel

Inherits:
Dry::Struct
  • Object
show all
Extended by:
Core::Utils
Defined in:
lib/etl/integrations/protocol/protocol.rb

Class Method Summary collapse

Methods included from Core::Utils

build_catalog, build_stream, convert_to_json_schema, create_log_message, extract_data, handle_exception, keys_to_symbols, logger, map_type_to_json_schema, success?

Class Method Details

.from_json(json_string) ⇒ Object



33
34
35
36
# File 'lib/etl/integrations/protocol/protocol.rb', line 33

def from_json(json_string)
  data = JSON.parse(json_string)
  new(keys_to_symbols(data))
end