Documentation ¶
Index ¶
- func NewLinkManager(linkStore LinkStore, socialGraphManager om.SocialGraphManager, ...) (om.LinkManager, error)
- type DbLinkStore
- func (s *DbLinkStore) AddLink(request om.AddLinkRequest) (link *om.Link, err error)
- func (s *DbLinkStore) DeleteLink(username string, url string) (err error)
- func (s *DbLinkStore) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
- func (s *DbLinkStore) UpdateLink(request om.UpdateLinkRequest) (link *om.Link, err error)
- type InMemoryLinkStore
- func (m *InMemoryLinkStore) AddLink(request om.AddLinkRequest) (link *om.Link, err error)
- func (m *InMemoryLinkStore) DeleteLink(username string, url string) error
- func (m *InMemoryLinkStore) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
- func (m *InMemoryLinkStore) UpdateLink(request om.UpdateLinkRequest) (link *om.Link, err error)
- type LinkManager
- func (m *LinkManager) AddLink(request om.AddLinkRequest) (err error)
- func (m *LinkManager) DeleteLink(username string, url string) (err error)
- func (m *LinkManager) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
- func (m *LinkManager) UpdateLink(request om.UpdateLinkRequest) (err error)
- type LinkStore
- type UserLinks
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewLinkManager ¶
func NewLinkManager(linkStore LinkStore, socialGraphManager om.SocialGraphManager, eventSink om.LinkManagerEvents) (om.LinkManager, error)
Types ¶
type DbLinkStore ¶
type DbLinkStore struct {
// contains filtered or unexported fields
}
func NewDbLinkStore ¶
func (*DbLinkStore) AddLink ¶
func (s *DbLinkStore) AddLink(request om.AddLinkRequest) (link *om.Link, err error)
func (*DbLinkStore) DeleteLink ¶
func (s *DbLinkStore) DeleteLink(username string, url string) (err error)
func (*DbLinkStore) GetLinks ¶
func (s *DbLinkStore) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
func (*DbLinkStore) UpdateLink ¶
func (s *DbLinkStore) UpdateLink(request om.UpdateLinkRequest) (link *om.Link, err error)
type InMemoryLinkStore ¶
Link store is a map of username:UserLinks
func (*InMemoryLinkStore) AddLink ¶
func (m *InMemoryLinkStore) AddLink(request om.AddLinkRequest) (link *om.Link, err error)
func (*InMemoryLinkStore) DeleteLink ¶
func (m *InMemoryLinkStore) DeleteLink(username string, url string) error
func (*InMemoryLinkStore) GetLinks ¶
func (m *InMemoryLinkStore) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
func (*InMemoryLinkStore) UpdateLink ¶
func (m *InMemoryLinkStore) UpdateLink(request om.UpdateLinkRequest) (link *om.Link, err error)
type LinkManager ¶
type LinkManager struct {
// contains filtered or unexported fields
}
func (*LinkManager) AddLink ¶
func (m *LinkManager) AddLink(request om.AddLinkRequest) (err error)
func (*LinkManager) DeleteLink ¶
func (m *LinkManager) DeleteLink(username string, url string) (err error)
func (*LinkManager) GetLinks ¶
func (m *LinkManager) GetLinks(request om.GetLinksRequest) (result om.GetLinksResult, err error)
func (*LinkManager) UpdateLink ¶
func (m *LinkManager) UpdateLink(request om.UpdateLinkRequest) (err error)
type LinkStore ¶
type LinkStore interface { GetLinks(request om.GetLinksRequest) (om.GetLinksResult, error) AddLink(request om.AddLinkRequest) (*om.Link, error) UpdateLink(request om.UpdateLinkRequest) (*om.Link, error) DeleteLink(username string, url string) error }
Click to show internal directories.
Click to hide internal directories.