zeekay 4e69f376f3 docs: add NOTICE attributing upstream OSS
ZAP is a derivative work; this NOTICE credits the upstream project, its
original authors, and license, alongside the unchanged LICENSE.
2026-06-21 07:39:00 -07:00
2016-10-08 17:16:03 +03:00

zap-proto/scala

Docs: ZAP Scala SDK · part of the ZAP Protocol

Scala 3 / Scala.js implementation of ZAP (Zero-copy App Proto). Idiomatic case classes, opaque types for zero-allocation reads.

Install

// build.sbt
libraryDependencies += "io.zap-proto" %% "zap" % "0.1.0"

Generate code

zap compile -o ./src/main/scala/gen --scala schema/*.zap

Encode / decode

import zap.proto.*

@main def run() =
  val msg = gen.Message(id = 42, name = "hello")
  val bytes = msg.toBytes
  val decoded = gen.Message.fromBytes(bytes)
  println(s"\${decoded.id} \${decoded.name}")

License

MIT

S
Description
ZAP for Scala
Readme
459 KiB
Languages
Scala 96%
ZAP 3.9%
HTML 0.1%