Sha256: ede02a023f4aa54b7f46268c2abf9903e180adce3d137d96a36ec27365c2ef52

Contents?: true

Size: 351 Bytes

Versions: 1

Compression:

Stored size: 351 Bytes

Contents

class Array
  # Formats an array into a string suitable for a CAP message.
  #
  # @return [String]
  # @example
  #   [ "one", "two words", "three" ].to_s_for_cap # => "one \"two words\" three"
  # @see String#unpack_cap_list
  def to_s_for_cap
    self.map{ |element| element.to_s.for_cap_list }.join( ' ' )
  end

  def blank?
    empty?
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rcap-2.4.0 lib/rcap/extensions/array.rb