Class: HashString
- Inherits:
-
Object
- Object
- HashString
- Defined in:
- lib/generators/ruby_rabbitmq_janus/create_request_generator.rb
Overview
Create an hash with an array
Instance Method Summary collapse
-
#convert_in_hash ⇒ Object
Create and return an hash.
-
#initialize(string_array) ⇒ HashString
constructor
Initialize an array.
Constructor Details
#initialize(string_array) ⇒ HashString
Initialize an array
26 27 28 29 |
# File 'lib/generators/ruby_rabbitmq_janus/create_request_generator.rb', line 26 def initialize(string_array) @array = string_array @hash = {} end |
Instance Method Details
#convert_in_hash ⇒ Object
Create and return an hash
32 33 34 35 |
# File 'lib/generators/ruby_rabbitmq_janus/create_request_generator.rb', line 32 def convert_in_hash @hash[@array[0]] = test_string_hash @hash end |