Skip to content

Commit

Permalink
deploy: d501711
Browse files Browse the repository at this point in the history
  • Loading branch information
satabin committed Oct 9, 2024
1 parent 9e8dfdb commit 931c7d8
Show file tree
Hide file tree
Showing 16 changed files with 32 additions and 32 deletions.
2 changes: 1 addition & 1 deletion cookbooks/jq/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ <h3 id="transforming" class="section"><a class="anchor-link left" href="#transfo
<pre class="keep-together pdf epub"><code class="nohighlight"><span class="keyword">import</span><span> </span><span class="identifier">fs2</span><span>.</span><span class="identifier">data</span><span>.</span><span class="identifier">json</span><span>.</span><span class="identifier">jq</span><span>.</span><span class="type-name">Compiler</span><span>

</span><span class="keyword">val</span><span> </span><span class="identifier">queryCompiler</span><span> = </span><span class="type-name">Compiler</span><span>[</span><span class="type-name">IO</span><span>]
</span><span class="comment">// queryCompiler: Compiler[IO] = fs2.data.json.jq.internal.ESPJqCompiler@5933ae2d
</span><span class="comment">// queryCompiler: Compiler[IO] = fs2.data.json.jq.internal.ESPJqCompiler@15639f14
</span><span>
</span><span class="keyword">val</span><span> </span><span class="identifier">queryPipe</span><span> = </span><span class="identifier">queryCompiler</span><span>.</span><span class="identifier">compile</span><span>(</span><span class="identifier">query</span><span>).</span><span class="identifier">unsafeRunSync</span><span>()
</span><span class="comment">// queryPipe: fs2.package.Pipe[IO, json.Token, json.Token] = &lt;function1&gt;</span></code></pre>
Expand Down
4 changes: 2 additions & 2 deletions documentation/cbor-json/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ <h2 id="json-to-cbor" class="section"><a class="anchor-link left" href="#json-to
// NegativeInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@2e1b2960,
// at = scodec.bits.ByteVector$AtArray@7866422f,
// offset = 0L,
// size = 1L
// )
Expand All @@ -273,7 +273,7 @@ <h2 id="json-to-cbor" class="section"><a class="anchor-link left" href="#json-to
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@7e92a5d8,
// at = scodec.bits.ByteVector$AtArray@620582b7,
// offset = 0L,
// size = 2L
// )
Expand Down
30 changes: 15 additions & 15 deletions documentation/cbor/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ <h3 id="parsing-1" class="section"><a class="anchor-link left" href="#parsing-1"
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@226577fe,
// at = scodec.bits.ByteVector$AtArray@51a5c439,
// offset = 0L,
// size = 1L
// )
Expand All @@ -197,7 +197,7 @@ <h3 id="parsing-1" class="section"><a class="anchor-link left" href="#parsing-1"
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@714971fb,
// at = scodec.bits.ByteVector$AtArray@7510ad6d,
// offset = 0L,
// size = 1L
// )
Expand All @@ -206,7 +206,7 @@ <h3 id="parsing-1" class="section"><a class="anchor-link left" href="#parsing-1"
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@76561dc4,
// at = scodec.bits.ByteVector$AtArray@361668b1,
// offset = 0L,
// size = 1L
// )
Expand All @@ -216,7 +216,7 @@ <h3 id="parsing-1" class="section"><a class="anchor-link left" href="#parsing-1"
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@5297d011,
// at = scodec.bits.ByteVector$AtArray@10cd9a11,
// offset = 0L,
// size = 1L
// )
Expand All @@ -225,7 +225,7 @@ <h3 id="parsing-1" class="section"><a class="anchor-link left" href="#parsing-1"
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@5b44973a,
// at = scodec.bits.ByteVector$AtArray@6f36103d,
// offset = 0L,
// size = 1L
// )
Expand Down Expand Up @@ -340,7 +340,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@94200a3,
// at = scodec.bits.ByteVector$AtArray@488f8086,
// offset = 0L,
// size = 1L
// )
Expand All @@ -350,7 +350,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@298f3319,
// at = scodec.bits.ByteVector$AtArray@2c7448a,
// offset = 0L,
// size = 1L
// )
Expand All @@ -359,7 +359,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@4a73aa9,
// at = scodec.bits.ByteVector$AtArray@4e3a6fe1,
// offset = 0L,
// size = 1L
// )
Expand All @@ -369,7 +369,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@6f403e1a,
// at = scodec.bits.ByteVector$AtArray@3f9a8651,
// offset = 0L,
// size = 1L
// )
Expand All @@ -378,7 +378,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@769e7c49,
// at = scodec.bits.ByteVector$AtArray@ba5aa94,
// offset = 0L,
// size = 1L
// )
Expand All @@ -400,7 +400,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@7548c7fe,
// at = scodec.bits.ByteVector$AtArray@4565db0c,
// offset = 0L,
// size = 1L
// )
Expand All @@ -410,7 +410,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@70b1812a,
// at = scodec.bits.ByteVector$AtArray@63b2383e,
// offset = 0L,
// size = 1L
// )
Expand All @@ -419,7 +419,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@1a716b1a,
// at = scodec.bits.ByteVector$AtArray@22ee959a,
// offset = 0L,
// size = 1L
// )
Expand All @@ -429,7 +429,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@351bf7f6,
// at = scodec.bits.ByteVector$AtArray@3f913310,
// offset = 0L,
// size = 1L
// )
Expand All @@ -438,7 +438,7 @@ <h3 id="serializing-2" class="section"><a class="anchor-link left" href="#serial
// PositiveInt(
// bytes = Chunk(
// bytes = View(
// at = scodec.bits.ByteVector$AtArray@65fa19c,
// at = scodec.bits.ByteVector$AtArray@54c73255,
// offset = 0L,
// size = 1L
// )
Expand Down
14 changes: 7 additions & 7 deletions documentation/csv/generic/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ <h2 id="derivation-of-celldecoder-cellencoder" class="section"><a class="anchor-
}

</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">stateDecoder</span><span> = </span><span class="identifier">deriveCellDecoder</span><span>[</span><span class="type-name">State</span><span>]
</span><span class="comment">// stateDecoder: CellDecoder[State] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$coproductDecoder$3@36a40e47
</span><span class="comment">// stateDecoder: CellDecoder[State] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$coproductDecoder$3@217a0ca3
// use stateDecoder to derive decoders for rows...or just test:
</span><span class="identifier">stateDecoder</span><span>(</span><span class="string-literal">&quot;On&quot;</span><span>)
</span><span class="comment">// res1: DecoderResult[State] = Right(value = On)
Expand All @@ -199,7 +199,7 @@ <h2 id="derivation-of-celldecoder-cellencoder" class="section"><a class="anchor-
</span><span>
</span><span class="comment">// same goes for the encoder
</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">stateEncoder</span><span> = </span><span class="identifier">deriveCellEncoder</span><span>[</span><span class="type-name">State</span><span>]
</span><span class="comment">// stateEncoder: CellEncoder[State] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$coproductEncoder$3@b08ffea
</span><span class="comment">// stateEncoder: CellEncoder[State] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$coproductEncoder$3@4e12cdce
</span><span class="identifier">stateEncoder</span><span>(</span><span class="type-name">State</span><span>.</span><span class="type-name">On</span><span>)
</span><span class="comment">// res3: String = &quot;On&quot;</span></code></pre>
<p>The generic derivation for cell decoders also supports renaming and deriving instances for unary product types (case classes with one field):</p>
Expand All @@ -213,19 +213,19 @@ <h2 id="derivation-of-celldecoder-cellencoder" class="section"><a class="anchor-

</span><span class="comment">// works as we have an implicit CellDecoder[String]
</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">unknownDecoder</span><span> = </span><span class="identifier">deriveCellDecoder</span><span>[</span><span class="type-name">Advanced</span><span>.</span><span class="type-name">Unknown</span><span>]
</span><span class="comment">// unknownDecoder: CellDecoder[Advanced.Unknown] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$unaryProductDecoder$3@5243d624
</span><span class="comment">// unknownDecoder: CellDecoder[Advanced.Unknown] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$unaryProductDecoder$3@666083b8
</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">advancedDecoder</span><span> = </span><span class="identifier">deriveCellDecoder</span><span>[</span><span class="type-name">Advanced</span><span>]
</span><span class="comment">// advancedDecoder: CellDecoder[Advanced] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$coproductDecoder$3@4f85a206
</span><span class="comment">// advancedDecoder: CellDecoder[Advanced] = fs2.data.csv.generic.internal.DerivedCellDecoder$$anonfun$coproductDecoder$3@72fe0058
</span><span>
</span><span class="identifier">advancedDecoder</span><span>(</span><span class="string-literal">&quot;Active&quot;</span><span>)
</span><span class="comment">// res4: DecoderResult[Advanced] = Right(value = On)
</span><span class="identifier">advancedDecoder</span><span>(</span><span class="string-literal">&quot;Off&quot;</span><span>)
</span><span class="comment">// res5: DecoderResult[Advanced] = Right(value = Unknown(name = &quot;Off&quot;))
</span><span>
</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">unknownEncoder</span><span> = </span><span class="identifier">deriveCellEncoder</span><span>[</span><span class="type-name">Advanced</span><span>.</span><span class="type-name">Unknown</span><span>]
</span><span class="comment">// unknownEncoder: CellEncoder[Advanced.Unknown] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$unaryProductEncoder$3@706cc623
</span><span class="comment">// unknownEncoder: CellEncoder[Advanced.Unknown] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$unaryProductEncoder$3@641e213f
</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="identifier">advancedEncoder</span><span> = </span><span class="identifier">deriveCellEncoder</span><span>[</span><span class="type-name">Advanced</span><span>]
</span><span class="comment">// advancedEncoder: CellEncoder[Advanced] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$coproductEncoder$3@34a772ed
</span><span class="comment">// advancedEncoder: CellEncoder[Advanced] = fs2.data.csv.generic.internal.DerivedCellEncoder$$anonfun$coproductEncoder$3@238f44b2
</span><span>
</span><span class="identifier">advancedEncoder</span><span>(</span><span class="type-name">Advanced</span><span>.</span><span class="type-name">On</span><span>)
</span><span class="comment">// res6: String = &quot;Active&quot;
Expand Down Expand Up @@ -269,7 +269,7 @@ <h2 id="derivation-of-csvrowdecoder" class="section"><a class="anchor-link left"
<pre><code class="nohighlight"><span class="keyword">import</span><span> </span><span class="identifier">fs2</span><span>.</span><span class="identifier">data</span><span>.</span><span class="identifier">csv</span><span>.</span><span class="identifier">generic</span><span>.</span><span class="identifier">semiauto</span><span>.</span><span class="identifier">_</span><span>

</span><span class="keyword">implicit</span><span> </span><span class="keyword">val</span><span> </span><span class="type-name">MyRowDecoder</span><span>: </span><span class="type-name">CsvRowDecoder</span><span>[</span><span class="type-name">MyRow</span><span>, </span><span class="type-name">String</span><span>] = </span><span class="identifier">deriveCsvRowDecoder</span><span>[</span><span class="type-name">MyRow</span><span>]
</span><span class="comment">// MyRowDecoder: CsvRowDecoder[MyRow, String] = fs2.data.csv.generic.internal.DerivedCsvRowDecoder$$anon$1@4df50540
</span><span class="comment">// MyRowDecoder: CsvRowDecoder[MyRow, String] = fs2.data.csv.generic.internal.DerivedCsvRowDecoder$$anon$1@2660fe0d
</span><span>
</span><span class="keyword">val</span><span> </span><span class="identifier">decoded</span><span> = </span><span class="identifier">stream</span><span>.</span><span class="identifier">through</span><span>(</span><span class="identifier">decodeUsingHeaders</span><span>[</span><span class="type-name">MyRow</span><span>]())
</span><span class="comment">// decoded: Stream[[x]Fallible[x], MyRow] = Stream(..)
Expand Down
Loading

0 comments on commit 931c7d8

Please sign in to comment.