Move implementations for IsLink
This commit is contained in:
parent
fa5b0e2012
commit
e630cf771c
3 changed files with 63 additions and 3 deletions
|
@ -34,9 +34,9 @@ func (i *InboxStream) Append(o ObjectOrLink) error {
|
|||
}
|
||||
|
||||
// Append adds an element to an Inbox
|
||||
func (o *Inbox) Append(ob ObjectOrLink) error {
|
||||
o.OrderedItems = append(o.OrderedItems, ob)
|
||||
o.TotalItems++
|
||||
func (i *Inbox) Append(ob ObjectOrLink) error {
|
||||
i.OrderedItems = append(i.OrderedItems, ob)
|
||||
i.TotalItems++
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -49,3 +49,23 @@ func (i InboxStream) GetID() ObjectID {
|
|||
func (i InboxStream) GetType() ActivityVocabularyType {
|
||||
return i.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an InboxStream object
|
||||
func (i InboxStream) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// GetID returns the ObjectID corresponding to Inbox
|
||||
func (i Inbox) GetID() ObjectID {
|
||||
return i.ID
|
||||
}
|
||||
|
||||
// GetType returns the Inbox's type
|
||||
func (i Inbox) GetType() ActivityVocabularyType {
|
||||
return i.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an Inbox object
|
||||
func (i Inbox) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
|
|
@ -48,3 +48,23 @@ func (l LikedCollection) GetID() ObjectID {
|
|||
func (l LikedCollection) GetType() ActivityVocabularyType {
|
||||
return l.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an LikedCollection object
|
||||
func (l LikedCollection) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// GetID returns the ObjectID corresponding to the Liked
|
||||
func (l Liked) GetID() ObjectID {
|
||||
return l.ID
|
||||
}
|
||||
|
||||
// GetType returns the Liked's type
|
||||
func (l Liked) GetType() ActivityVocabularyType {
|
||||
return l.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an Liked object
|
||||
func (l Liked) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
|
|
@ -47,3 +47,23 @@ func (o OutboxStream) GetID() ObjectID {
|
|||
func (o OutboxStream) GetType() ActivityVocabularyType {
|
||||
return o.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an OutboxStream object
|
||||
func (o OutboxStream) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// GetID returns the ObjectID corresponding to Outbox
|
||||
func (o Outbox) GetID() ObjectID {
|
||||
return o.ID
|
||||
}
|
||||
|
||||
// GetType returns the Outbox's type
|
||||
func (o Outbox) GetType() ActivityVocabularyType {
|
||||
return o.Type
|
||||
}
|
||||
|
||||
// IsLink returns false for an Outbox object
|
||||
func (o Outbox) IsLink() bool {
|
||||
return false
|
||||
}
|
||||
|
|
Reference in a new issue