novel

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 28, 2015 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Novels... obviously...

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyDefaultFor

func CopyDefaultFor(userId string)

Copy the default novels to the newly subscribed user

func Exists

func Exists(userId string) bool

Check if the given user has novels

Types

type Novel

type Novel struct {
	NovelId  string `json:"novelId"`
	UserId   string `json:"-"`
	Title    string `json:"title"`
	Url      string `json:"url"`
	ImageUrl string `json:"imageUrl"`
	Summary  string `json:"summary"`
	Favorite bool   `json:"favorite"`
	feed.Feed
}

The Novel representation

func Get

func Get(novelId, userId string) *Novel

Get the Novel given an novelId

func GetList

func GetList(userId string) []*Novel

Fetch the list of novels

func New

func New() *Novel

Instanciate a new Novel

func Search(userId, title string) []*Novel

Search the list of novels given a string

func (*Novel) Delete

func (n *Novel) Delete()

Delete a novel

func (*Novel) IsValid

func (n *Novel) IsValid() bool

Check if the novel has valid attributes

func (*Novel) Save

func (n *Novel) Save()

Save the novel in the database

func (*Novel) Update

func (n *Novel) Update()

Update the novel in the database

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL