honey_format 0.22.0 → 0.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ad367da18e5936281cd7b07a99de44bbc93313855a9385a0bda46db97bda97dc
4
- data.tar.gz: 04f157b49ff97adc9368766e14694a9fbda96eca0b06950857c0e00c09c59f3e
3
+ metadata.gz: 54b1c442221f4921f054ba328b55f066166d27b27bd56aa8499bf195bac65847
4
+ data.tar.gz: 58977315c3fb95a54a0cbc7ab930a8ade04016865c589f4e6374ce113a080c1c
5
5
  SHA512:
6
- metadata.gz: 53ecde3518fade3c5c4610fe1d5b0d806d96a07408fe5eb73eba7ecec37d8c5ce31c86c0f1ded38b6d7bee05b2027073f167fc0cc29abb7a8b71132734320cd5
7
- data.tar.gz: 57debe9b620dc990220926a4944172e939dcf7f40dc087016e5c401e967ed7094f818d607fd72e33a592464456358fd519565bdd01ff62f2a3aaedec9f9f3534
6
+ metadata.gz: 1cbbc61c953422dea9de989ebe429b05325140868c54b2861dbaafac222425706d8af481d86c0a0f3a75bbc19bcabfb5d580d0261c0a3ba928c3a2d45390abf7
7
+ data.tar.gz: d07789988d8ad6f335fa517bc07954f0f9800c3dce3ab10a9295c6edae81994fd78ca9ed2e44c6ac6b8759593e0807edeb78457bbb54ce4e348db116f953374a
@@ -1,5 +1,9 @@
1
1
  # HEAD
2
2
 
3
+ ## v0.23.0
4
+
5
+ * Add `Rows#columnns` method that returns header columns
6
+
3
7
  ## v0.22.0
4
8
 
5
9
  * Add `Matrix#type_map` and ignore non-existing column in the type map. [PR#64](https://github.com/buren/honey_format/pull/64). Thank you [@prem-prakash](https://github.com/prem-prakash).
@@ -16,10 +16,17 @@ module HoneyFormat
16
16
  # @raise [EmptyRowColumnsError] raised when there are no columns.
17
17
  # @raise [InvalidRowLengthError] raised when row has more columns than header columns.
18
18
  def initialize(rows, columns, builder: nil, type_map: {})
19
- builder = RowBuilder.new(columns, builder: builder, type_map: type_map)
19
+ @columns = columns
20
+ builder = RowBuilder.new(@columns, builder: builder, type_map: type_map)
20
21
  @rows = prepare_rows(builder, rows)
21
22
  end
22
23
 
24
+ # Row columns
25
+ # @return [Array<Symbol>] of column identifiers.
26
+ def columns
27
+ @columns
28
+ end
29
+
23
30
  # Returns true if rows contains no elements.
24
31
  # @return [true, false] true if rows contains no elements.
25
32
  def empty?
@@ -4,7 +4,7 @@ module HoneyFormat
4
4
  # Gem version
5
5
  VERSION = [
6
6
  MAJOR_VERSION = 0,
7
- MINOR_VERSION = 22,
7
+ MINOR_VERSION = 23,
8
8
  PATCH_VERSION = 0,
9
9
  ].join('.')
10
10
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: honey_format
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.22.0
4
+ version: 0.23.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jacob Burenstam
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-11-26 00:00:00.000000000 Z
11
+ date: 2020-11-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: benchmark-ips