2023-01-11 19:42:06 -07:00
|
|
|
package webfinger
|
|
|
|
|
|
|
|
import (
|
|
|
|
"encoding/json"
|
|
|
|
|
2023-02-26 22:33:01 -07:00
|
|
|
"go.sour.is/ev/pkg/es/event"
|
2023-01-11 19:42:06 -07:00
|
|
|
)
|
|
|
|
|
|
|
|
type SubjectSet struct {
|
|
|
|
Subject string `json:"subject"`
|
|
|
|
Aliases []string `json:"aliases,omitempty"`
|
|
|
|
Properties map[string]*string `json:"properties,omitempty"`
|
|
|
|
|
2023-04-02 16:45:17 -06:00
|
|
|
event.IsEvent
|
2023-01-11 19:42:06 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
func (e *SubjectSet) MarshalBinary() (text []byte, err error) {
|
|
|
|
return json.Marshal(e)
|
|
|
|
}
|
|
|
|
func (e *SubjectSet) UnmarshalBinary(b []byte) error {
|
|
|
|
return json.Unmarshal(b, e)
|
|
|
|
}
|
|
|
|
|
|
|
|
var _ event.Event = (*SubjectSet)(nil)
|
|
|
|
|
|
|
|
type SubjectDeleted struct {
|
2023-02-26 22:33:01 -07:00
|
|
|
Subject string `json:"subject"`
|
2023-01-11 19:42:06 -07:00
|
|
|
|
2023-04-02 16:45:17 -06:00
|
|
|
event.IsEvent
|
2023-01-11 19:42:06 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
func (e *SubjectDeleted) MarshalBinary() (text []byte, err error) {
|
|
|
|
return json.Marshal(e)
|
|
|
|
}
|
|
|
|
func (e *SubjectDeleted) UnmarshalBinary(b []byte) error {
|
|
|
|
return json.Unmarshal(b, e)
|
|
|
|
}
|
|
|
|
|
|
|
|
var _ event.Event = (*SubjectDeleted)(nil)
|
|
|
|
|
|
|
|
type LinkSet struct {
|
|
|
|
Rel string `json:"rel"`
|
|
|
|
Type string `json:"type,omitempty"`
|
|
|
|
HRef string `json:"href,omitempty"`
|
|
|
|
Titles map[string]string `json:"titles,omitempty"`
|
|
|
|
Properties map[string]*string `json:"properties,omitempty"`
|
|
|
|
|
2023-04-02 16:45:17 -06:00
|
|
|
event.IsEvent
|
2023-01-11 19:42:06 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
func (e *LinkSet) MarshalBinary() (text []byte, err error) {
|
|
|
|
return json.Marshal(e)
|
|
|
|
}
|
|
|
|
func (e *LinkSet) UnmarshalBinary(b []byte) error {
|
|
|
|
return json.Unmarshal(b, e)
|
|
|
|
}
|
|
|
|
|
|
|
|
var _ event.Event = (*LinkSet)(nil)
|
|
|
|
|
|
|
|
type LinkDeleted struct {
|
|
|
|
Rel string `json:"rel"`
|
|
|
|
|
2023-04-02 16:45:17 -06:00
|
|
|
event.IsEvent
|
2023-01-11 19:42:06 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
func (e *LinkDeleted) MarshalBinary() (text []byte, err error) {
|
|
|
|
return json.Marshal(e)
|
|
|
|
}
|
|
|
|
func (e *LinkDeleted) UnmarshalBinary(b []byte) error {
|
|
|
|
return json.Unmarshal(b, e)
|
|
|
|
}
|
|
|
|
|
|
|
|
var _ event.Event = (*LinkDeleted)(nil)
|