mirror of
https://github.com/Luzifer/sii.git
synced 2024-12-21 00:21:15 +00:00
Add DeliveryLog / DeliveryLogEntry
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
a40e9a5c6e
commit
551cd6682d
1 changed files with 36 additions and 0 deletions
36
block_delivery_log.go
Normal file
36
block_delivery_log.go
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
package sii
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
RegisterBlock(&DeliveryLog{})
|
||||||
|
RegisterBlock(&DeliveryLogEntry{})
|
||||||
|
}
|
||||||
|
|
||||||
|
type DeliveryLog struct {
|
||||||
|
Version int `sii:"version"`
|
||||||
|
Entries []Ptr `sii:"entries"`
|
||||||
|
CachedJobCount int64 `sii:"cached_jobs_count"`
|
||||||
|
|
||||||
|
blockName string
|
||||||
|
}
|
||||||
|
|
||||||
|
func (DeliveryLog) Class() string { return "delivery_log" }
|
||||||
|
|
||||||
|
func (d *DeliveryLog) Init(class, name string) {
|
||||||
|
d.blockName = name
|
||||||
|
}
|
||||||
|
|
||||||
|
func (d DeliveryLog) Name() string { return d.blockName }
|
||||||
|
|
||||||
|
type DeliveryLogEntry struct {
|
||||||
|
Params []RawValue `sii:"params"`
|
||||||
|
|
||||||
|
blockName string
|
||||||
|
}
|
||||||
|
|
||||||
|
func (DeliveryLogEntry) Class() string { return "delivery_log_entry" }
|
||||||
|
|
||||||
|
func (d *DeliveryLogEntry) Init(class, name string) {
|
||||||
|
d.blockName = name
|
||||||
|
}
|
||||||
|
|
||||||
|
func (d DeliveryLogEntry) Name() string { return d.blockName }
|
Loading…
Reference in a new issue