uri-ni 0.2.5 → 0.2.6

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: 971b72993168c64b86e07c62460ba32c22f3d2849f1b2bdcabf9d455b9ab320a
4
- data.tar.gz: 9e90ac190a4ef2a956d24d9f90d2b460cca4b2af18abc7b695ca0bf5ea80f371
3
+ metadata.gz: 7cbe676431b1f91e98bed13314dffd05357aa058e3e1b11efc3e19ee904ea927
4
+ data.tar.gz: 012f7ebfc11314f307437d7a531d92f7ad08e2dd19e251b1ab40fc71c985f103
5
5
  SHA512:
6
- metadata.gz: 8499f77ffdeb429a6b3d07021cfd4d825b492761bb780a2dff37fbee2c2955f2d7552aa3e11013bda54a04315bf3d8301b128abce4d3d8ea2048dc6b78b2ecfd
7
- data.tar.gz: '08399a8e69433a93246327d336776f879fddb2fc6bdfd38e97d125aa974c4fa92297097c1e48389a7a7c17076874f2ad607eed1861de01889951e3bfcb894566'
6
+ metadata.gz: a3b20a2fddaa8ec8b047215438afdd3dd54be09a4d91b3deb6fd6885bf9a7da7e3791ec126926f4f5853203943bda9a5eeb49d1aa6580d6b7d232131fbcc789a
7
+ data.tar.gz: ab5cf0c7504eac666b0a909fedaada251890d47ac0de45c9924de7c07ca584f0da8be0588345283d34ae08dae9d24c296b9dc3bc82ce9c383b3c74abba028035
@@ -3,7 +3,7 @@ require 'uri/generic'
3
3
 
4
4
  module URI
5
5
  class NI < Generic
6
- VERSION = "0.2.5"
6
+ VERSION = "0.2.6".freeze
7
7
  end
8
8
 
9
9
  # might as well put this here
data/lib/uri/ni.rb CHANGED
@@ -289,7 +289,7 @@ class URI::NI < URI::Generic
289
289
  blocksize: blocksize, authority: authority, query: query, &block
290
290
  end
291
291
 
292
- # Return a Digest::Instance for a supported algorithm.
292
+ # Return a {Digest::Instance} for a supported algorithm.
293
293
  # @param [#to_s, #to_sym] The algorithm
294
294
  # @return [Digest:Instance] The digest context
295
295
  # @raise [ArgumentError] if the algorithm is unrecognized
@@ -402,6 +402,12 @@ class URI::NI < URI::Generic
402
402
  a.to_sym if a
403
403
  end
404
404
 
405
+ # Return a `Hash` mapping algorithms to their lengths
406
+ #
407
+ def self.lengths truncated: false
408
+ LENGTHS.slice *algorithms(truncated: truncated)
409
+ end
410
+
405
411
  # Obtain the authority (userinfo@host:port) if present.
406
412
  #
407
413
  # @return [String, nil] the authority
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uri-ni
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dorian Taylor