This project contains the low-level object framework Zip API. It enables Kubernetes-inspired objects without the hassle of code generation.
To define your objects using the framework, simply import api.zip
and declare
a zip.Object
along with a Spec and Status to get started.
import "api.zip"
type BookSpec struct {
Name string
Author string
}
type BookState string
const (
BookStateAvailable = BookState("available")
BookStateUnavailable = BookState("unavailable")
)
type BookStatus struct {
State BookState
}
type (
Book = zip.Object[BookSpec, BookStatus]
BookList = zip.ObjectList[BookSpec, BookStatus]
)
The Zip API Object Framework is licensed under BSD-3-Clause.