feat: initial commit
This commit is contained in:
commit
a161b86c9a
705 changed files with 288162 additions and 0 deletions
24
vendor/sourcery.dny.nu/pana/article.go
vendored
Normal file
24
vendor/sourcery.dny.nu/pana/article.go
vendored
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
package pana
|
||||
|
||||
import (
|
||||
ld "sourcery.dny.nu/longdistance"
|
||||
as "sourcery.dny.nu/pana/vocab/w3/activitystreams"
|
||||
)
|
||||
|
||||
// Article is the ActivityStreams Article type.
|
||||
type Article Object
|
||||
|
||||
// NewArticle initialises a new Article.
|
||||
func NewArticle() *Article {
|
||||
return &Article{
|
||||
Properties: make(ld.Properties),
|
||||
Type: []string{as.TypeArticle},
|
||||
}
|
||||
}
|
||||
|
||||
// Build finalises the Article.
|
||||
//
|
||||
// This returns [Any] since that's what [Activity.SetObject] expects.
|
||||
func (a *Article) Build() Any {
|
||||
return Any(*a)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue