Module: ModularizationStatistics::Tags
- Extended by:
- T::Sig
- Defined in:
- lib/modularization_statistics/tags.rb
Class Method Summary collapse
Class Method Details
.for(colon_delimited_tag_strings) ⇒ Object
8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/modularization_statistics/tags.rb', line 8 def self.for(colon_delimited_tag_strings) colon_delimited_tag_strings.map do |colon_delimited_tag_string| key, value = colon_delimited_tag_string.split(':') raise StandardError, "Improperly formatted tag `#{colon_delimited_tag_string}`" if key.nil? || value.nil? Tag.new( key: key, value: value ) end end |