Module: Emojidex::Data::CollectionMojiData
- Included in:
- Collection
- Defined in:
- lib/emojidex/data/collection/moji_data.rb
Overview
collects and condenses UTF moji codes within a collection
Instance Attribute Summary collapse
-
#moji_code_index ⇒ Object
readonly
Returns the value of attribute moji_code_index.
-
#moji_code_string ⇒ Object
readonly
Returns the value of attribute moji_code_string.
Instance Method Summary collapse
Instance Attribute Details
#moji_code_index ⇒ Object (readonly)
Returns the value of attribute moji_code_index.
5 6 7 |
# File 'lib/emojidex/data/collection/moji_data.rb', line 5 def moji_code_index @moji_code_index end |
#moji_code_string ⇒ Object (readonly)
Returns the value of attribute moji_code_string.
5 6 7 |
# File 'lib/emojidex/data/collection/moji_data.rb', line 5 def moji_code_string @moji_code_string end |
Instance Method Details
#condense_moji_code_data ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/emojidex/data/collection/moji_data.rb', line 7 def condense_moji_code_data @moji_code_string = '' @moji_code_index = {} @emoji.values.each do |moji| unless moji.moji.nil? @moji_code_string << moji.moji @moji_code_index[moji.moji] = moji.code end end end |