3 Commits

Author SHA1 Message Date
Adrian Zürcher
9d4d417856 fix typo 2025-06-19 18:49:35 +02:00
Adrian Zürcher
0446a160e1 add parameter haschild 2025-05-13 21:16:30 +02:00
Adrian Zürcher
640604c06d add create and has child parameter 2025-05-13 21:12:19 +02:00
4 changed files with 11 additions and 8 deletions

View File

@@ -10,6 +10,7 @@ type Get struct {
Drivers *Drivers `json:"driver,omitempty"` // assigned drivers Drivers *Drivers `json:"driver,omitempty"` // assigned drivers
Type Type `json:"type,omitempty"` // dbm datatype Type Type `json:"type,omitempty"` // dbm datatype
Value any `json:"value,omitempty"` // dbm value Value any `json:"value,omitempty"` // dbm value
HasChild bool `json:"hasChild,omitempty"` // inidicates path has child/ren
Rights Rights `json:"rights,omitempty"` // dbm read /write rights Rights Rights `json:"rights,omitempty"` // dbm read /write rights
} }

View File

@@ -49,7 +49,7 @@ func (r *Response) AddUnsubscription(sub Subscription) {
} }
// Add new data publish to response // Add new data publish to response
func (r *Response) AddUPublish(pub Publish) { func (r *Response) AddPublish(pub Publish) {
r.Publish = append(r.Publish, pub) r.Publish = append(r.Publish, pub)
} }

View File

@@ -11,6 +11,7 @@ type Set struct {
Type Type `json:"type,omitempty"` // dbm datatype Type Type `json:"type,omitempty"` // dbm datatype
Value any `json:"value,omitempty"` // dbm value Value any `json:"value,omitempty"` // dbm value
Rights Rights `json:"rights,omitempty"` // dbm read /write rights Rights Rights `json:"rights,omitempty"` // dbm read /write rights
Create bool `json:"create,omitempty"` // dbm create new datapoint
Updated bool `json:"-"` Updated bool `json:"-"`
} }

View File

@@ -8,6 +8,7 @@ type Subscription struct {
Path string `json:"path,omitempty"` // dbm path Path string `json:"path,omitempty"` // dbm path
Depth uint `json:"depth,omitempty"` // depth of subscriptions from found path or uuid Depth uint `json:"depth,omitempty"` // depth of subscriptions from found path or uuid
Value any `json:"value,omitempty"` // current value Value any `json:"value,omitempty"` // current value
HasChild bool `json:"hasChild,omitempty"` // inidicates path has child/ren
Drivers *Drivers `json:"drivers,omitempty"` // assigned drivers Drivers *Drivers `json:"drivers,omitempty"` // assigned drivers
Driver string `json:"driver,omitempty"` // driver type to assign this subscription Driver string `json:"driver,omitempty"` // driver type to assign this subscription
OnCreate bool `json:"onCreate,omitempty"` // notify at datapoint creation OnCreate bool `json:"onCreate,omitempty"` // notify at datapoint creation