Documentation ¶
Index ¶
- func AdminConf(repo repository.BoardRepository, mem BoardMemcache) func(*BoardService) *BoardService
- func EnvConf(env BoardEnvironment) func(*BoardService) *BoardService
- func RepoConf(repo repository.BoardRepository) func(*BoardService) *BoardService
- type AdminFunction
- func (admin *AdminFunction) CreateBoard(boardName string) error
- func (admin *AdminFunction) GetWriteCount() (_ int, err error)
- func (admin *AdminFunction) Login(passphrase, signature string) (string, error)
- func (admin *AdminFunction) Logout() error
- func (admin *AdminFunction) ResetWriteCount() error
- func (admin *AdminFunction) VerifySession(sessionId string) error
- type AlterMemcache
- type BoardEnvironment
- type BoardMemcache
- type BoardService
- func (sv *BoardService) ComputeId(ipAddr, boardName string) string
- func (sv *BoardService) CreateThread(stng bbscfg.Setting, boardName string, name, mail, id, message, title string) (threadKey string, err error)
- func (sv *BoardService) MakeDat(boardName, threadKey string) (_ []byte, _ time.Time, err error)
- func (sv *BoardService) MakeDatJson(boardName, threadKey string, ifModifiedSince string, min, max int) (_ []byte, err error)
- func (sv *BoardService) MakeSubjectJson(boardName string, limit int) (_ []byte, err error)
- func (sv *BoardService) MakeSubjectTxt(boardName string) (_ []byte, err error)
- func (sv *BoardService) StartedAt() time.Time
- func (sv *BoardService) WriteDat(stng bbscfg.Setting, boardName, threadKey, name, mail, id, message string) (resnum int, err error)
- type SysEnv
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AdminConf ¶
func AdminConf(repo repository.BoardRepository, mem BoardMemcache) func(*BoardService) *BoardService
func EnvConf ¶
func EnvConf(env BoardEnvironment) func(*BoardService) *BoardService
func RepoConf ¶
func RepoConf(repo repository.BoardRepository) func(*BoardService) *BoardService
Types ¶
type AdminFunction ¶
type AdminFunction struct {
// contains filtered or unexported fields
}
func (*AdminFunction) CreateBoard ¶
func (admin *AdminFunction) CreateBoard(boardName string) error
空の板を作成する。 すでに存在する場合エラーを返す。
func (*AdminFunction) GetWriteCount ¶
func (admin *AdminFunction) GetWriteCount() (_ int, err error)
func (*AdminFunction) Login ¶
func (admin *AdminFunction) Login(passphrase, signature string) (string, error)
func (*AdminFunction) Logout ¶
func (admin *AdminFunction) Logout() error
func (*AdminFunction) ResetWriteCount ¶
func (admin *AdminFunction) ResetWriteCount() error
func (*AdminFunction) VerifySession ¶
func (admin *AdminFunction) VerifySession(sessionId string) error
type AlterMemcache ¶
type AlterMemcache struct {
// contains filtered or unexported fields
}
func NewAlterMemcache ¶
func NewAlterMemcache(ctx context.Context, client *datastore.Client) *AlterMemcache
func (*AlterMemcache) Delete ¶
func (mem *AlterMemcache) Delete(key string) error
type BoardEnvironment ¶
type BoardMemcache ¶
type BoardService ¶
type BoardService struct { Admin *AdminFunction // contains filtered or unexported fields }
Dependency injection for Board
func DefaultBoardService ¶
func DefaultBoardService() (*BoardService, error)
func NewBoardService ¶
func NewBoardService(config ...func(*BoardService) *BoardService) *BoardService
func (*BoardService) ComputeId ¶
func (sv *BoardService) ComputeId(ipAddr, boardName string) string
func (*BoardService) CreateThread ¶
func (sv *BoardService) CreateThread(stng bbscfg.Setting, boardName string, name, mail, id, message, title string) (threadKey string, err error)
Creates a Thread
func (*BoardService) MakeDatJson ¶
func (sv *BoardService) MakeDatJson(boardName, threadKey string, ifModifiedSince string, min, max int) (_ []byte, err error)
データストアからエンティティを取得しdatをjsonとして返す
func (*BoardService) MakeSubjectJson ¶
func (sv *BoardService) MakeSubjectJson(boardName string, limit int) (_ []byte, err error)
データストアからエンティティを取得しjsonとして返す
func (*BoardService) MakeSubjectTxt ¶
func (sv *BoardService) MakeSubjectTxt(boardName string) (_ []byte, err error)
データストアからエンティティを取得しsubject.txtとして返す
func (*BoardService) StartedAt ¶
func (sv *BoardService) StartedAt() time.Time
Click to show internal directories.
Click to hide internal directories.