uinit-type 0.1.7 → 0.1.8
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 +4 -4
- data/lib/uinit/type/base.rb +5 -1
- data/lib/uinit/type/float.rb +8 -0
- data/lib/uinit/type/integer.rb +8 -0
- data/lib/uinit/type/string.rb +8 -0
- data/lib/uinit/type/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 43e2919517f943631ea31b1ccc01b0acc54c42ce9cb64947057f53678034959b
|
4
|
+
data.tar.gz: 2c3be6b8dbb8ccd9bd1b2b1fb7577b399dfc1a07418b165ec8e8aeb4f753e206
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d70e7d7c505f2a9c059a68b8a7868c64f2420e04259132a455afdbccc38e5a511aebae7477202b1bd9147aed7f544fb8377383ac1fca9cc2fcb394e24f21cea9
|
7
|
+
data.tar.gz: 52ff03846eb8635cd24b71530cf60598622262be10eb6fdedff71212a40bc97d49459169923d66e6462784eaeb870b0c5d542e3a3c89af15e8684195fb49f5d7
|
data/lib/uinit/type/base.rb
CHANGED
data/lib/uinit/type/float.rb
CHANGED
@@ -58,6 +58,14 @@ module Uinit
|
|
58
58
|
end
|
59
59
|
# rubocop:enable Metrics/PerceivedComplexity, Metrics/CyclomaticComplexity
|
60
60
|
|
61
|
+
def options
|
62
|
+
{ min:, max:, positive:, negative:, zero:, precision:, finite: }.compact
|
63
|
+
end
|
64
|
+
|
65
|
+
def inspect
|
66
|
+
"$#{name}[#{options.inspect}]"
|
67
|
+
end
|
68
|
+
|
61
69
|
private
|
62
70
|
|
63
71
|
def valid_precision?(value)
|
data/lib/uinit/type/integer.rb
CHANGED
data/lib/uinit/type/string.rb
CHANGED
data/lib/uinit/type/version.rb
CHANGED