iscc-lib 0.4.0-x86_64-linux → 0.6.0-x86_64-linux
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/iscc_lib/3.1/iscc_rb.so +0 -0
- data/lib/iscc_lib/3.2/iscc_rb.so +0 -0
- data/lib/iscc_lib/3.3/iscc_rb.so +0 -0
- data/lib/iscc_lib/version.rb +1 -1
- data/lib/iscc_lib.rb +18 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e91607ffb97f8342e26a3b3e5c4bd36944ffa7626f6e38ea612ee4cd764910b6
|
|
4
|
+
data.tar.gz: 4932e93d6cd6ffc7e7ac989279dc5c38aeef5be56a8d4de9768915b809fdae2a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 9b1385e800090fd4a856dc4a6f0da86193e4b443de1082266920ded43421e3ceb142c3081d286cfd2ba09cf7a2fbbf4c26e2c2873a4a0cdf226dcc4a07525ce4
|
|
7
|
+
data.tar.gz: feae97b50f058b0055f12710eebc76a967fa5eda98f63fc8d8ac0752512ccb8f26a01adab6b5b3ffb51ace472ee91eee0726671fb1fc0dc79ec53afc0a2bd934
|
data/lib/iscc_lib/3.1/iscc_rb.so
CHANGED
|
Binary file
|
data/lib/iscc_lib/3.2/iscc_rb.so
CHANGED
|
Binary file
|
data/lib/iscc_lib/3.3/iscc_rb.so
CHANGED
|
Binary file
|
data/lib/iscc_lib/version.rb
CHANGED
data/lib/iscc_lib.rb
CHANGED
|
@@ -63,6 +63,9 @@ module IsccLib
|
|
|
63
63
|
# Result from gen_sum_code_v0.
|
|
64
64
|
class SumCodeResult < Result; end
|
|
65
65
|
|
|
66
|
+
# Result from gen_iscc_id_v1.
|
|
67
|
+
class IdCodeResult < Result; end
|
|
68
|
+
|
|
66
69
|
# Generate a Meta-Code from name and optional metadata.
|
|
67
70
|
#
|
|
68
71
|
# @param name [String] content name (required, non-empty)
|
|
@@ -157,6 +160,21 @@ module IsccLib
|
|
|
157
160
|
SumCodeResult[_gen_sum_code_v0(path, bits, wide, add_units)]
|
|
158
161
|
end
|
|
159
162
|
|
|
163
|
+
# Generate an ISCC-IDv1 from a timestamp and a HUB-ID (experimental).
|
|
164
|
+
#
|
|
165
|
+
# Packs a 52-bit microsecond UTC timestamp and a 12-bit HUB-ID into an
|
|
166
|
+
# ISCC-ID unit with realm as SubType and Version V1. There is no dedicated
|
|
167
|
+
# decoder — use iscc_decode to decode.
|
|
168
|
+
#
|
|
169
|
+
# @param timestamp [Integer] microsecond UTC timestamp (0 <= timestamp < 2^52)
|
|
170
|
+
# @param hub_id [Integer] HUB-ID (0 <= hub_id < 4096)
|
|
171
|
+
# @param realm [Integer] realm (0 = testnet, 1 = mainnet)
|
|
172
|
+
# @return [IdCodeResult] hash with iscc
|
|
173
|
+
# @raise [RuntimeError] if any parameter is negative or out of range
|
|
174
|
+
def self.gen_iscc_id_v1(timestamp, hub_id, realm)
|
|
175
|
+
IdCodeResult[_gen_iscc_id_v1(timestamp, hub_id, realm)]
|
|
176
|
+
end
|
|
177
|
+
|
|
160
178
|
# Streaming Data-Code generator (reopens native class).
|
|
161
179
|
#
|
|
162
180
|
# Incrementally processes data with content-defined chunking and MinHash
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: iscc-lib
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.6.0
|
|
5
5
|
platform: x86_64-linux
|
|
6
6
|
authors:
|
|
7
7
|
- Titusz Pan
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-07-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: High-performance Ruby bindings for ISO 24138:2024 (ISCC). Native Rust
|
|
14
14
|
extension via Magnus for content identification and matching.
|