Documentation ¶
Index ¶
- Constants
- Variables
- type Chatroom
- type ChatroomManager
- func (this *ChatroomManager) AddTable()
- func (this *ChatroomManager) Count() int64
- func (this *ChatroomManager) Create(chatroom *Chatroom) *Chatroom
- func (this *ChatroomManager) Find(pagination *Pagination) []*Chatroom
- func (this *ChatroomManager) ListCacheKey(page int) string
- func (this *ChatroomManager) TableName() string
- type Model
- type ModelStats
- type Pagination
- type User
- type UserManager
Constants ¶
View Source
const (
PAGINATION_DEFAULT_LENGTH int = 10
)
Variables ¶
View Source
var (
DbMap *gorp.DbMap
)
Functions ¶
This section is empty.
Types ¶
type ChatroomManager ¶
type ChatroomManager struct { }
func (*ChatroomManager) AddTable ¶
func (this *ChatroomManager) AddTable()
func (*ChatroomManager) Count ¶
func (this *ChatroomManager) Count() int64
func (*ChatroomManager) Create ¶
func (this *ChatroomManager) Create(chatroom *Chatroom) *Chatroom
func (*ChatroomManager) Find ¶
func (this *ChatroomManager) Find(pagination *Pagination) []*Chatroom
func (*ChatroomManager) ListCacheKey ¶
func (this *ChatroomManager) ListCacheKey(page int) string
func (*ChatroomManager) TableName ¶
func (this *ChatroomManager) TableName() string
type ModelStats ¶
type ModelStats struct {
Count int64
}
type Pagination ¶
type Pagination struct { StartCount int EndCount int TotalCount int64 Page int MaxPage int Pages []int Length int Range int }
func NewPagination ¶
func NewPagination(page int, length int, totalCount int64) *Pagination
type UserManager ¶
type UserManager struct { }
func (*UserManager) AddTable ¶
func (this *UserManager) AddTable()
func (*UserManager) Count ¶
func (this *UserManager) Count(t int) int64
func (*UserManager) Create ¶
func (this *UserManager) Create(user *User) *User
func (*UserManager) Find ¶
func (this *UserManager) Find(t int, pagination *Pagination) []*User
func (*UserManager) TableName ¶
func (this *UserManager) TableName() string
Click to show internal directories.
Click to hide internal directories.