Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

hub state

Back to all declarations

Member

type

Member defines a type for board members.

Value

hub.Member

Board

type

Board defines a safe type for boards.

Value

hub.Board

NewSafeBoard

func(ref *boards.Board) hub.Board

NewSafeBoard creates a safe board.

Open
OID
008ef3…d59e:3
NewSafeBoard details

Inspect func

Comment

type

Comment defines a type for threads comment/replies.

Value

hub.Comment

NewSafeComment

func(ref *boards.Post) hub.Comment

NewSafeComment creates a safe comment.

Open
OID
008ef3…d59e:5
NewSafeComment details

Inspect func

timeToUnix

func(t time.Time) int64

timeToUnix converts time to Unix epoch.

Open
OID
008ef3…d59e:7
timeToUnix details

Inspect func

GetBoard

func(id uint64) (hub.Board, bool)

GetBoard returns a safe board.

Open
OID
008ef3…d59e:9
GetBoard details

Inspect func

GetThread

func(boardID uint64, threadID uint64) (hub.Thread, bool)

GetThread returns a safe board thread.

Open
OID
008ef3…d59e:11
GetThread details

Inspect func

GetComment

func(boardID uint64, threadID uint64, commentID uint64) (hub.Comment, bool)

GetComment returns a safe thread comment.

Open
OID
008ef3…d59e:12
GetComment details

Inspect func

GetBoards

func(start int, count int) []hub.Board

GetBoards returns a list with all boards. To reverse iterate use a negative count.

Open
OID
008ef3…d59e:13
GetBoards details

Inspect func

GetThreads

func(boardID uint64, start int, count int) []hub.Thread

GetThreads returns a list with threads of a board. To reverse iterate use a negative count.

Open
OID
008ef3…d59e:14
GetThreads details

Inspect func

GetMembers

func(boardID uint64, start int, count int) []boards.User

GetMembers returns a list with the members of a board. To reverse iterate use a negative count.

Open
OID
008ef3…d59e:15
GetMembers details

Inspect func

GetReposts

func(boardID uint64, threadID uint64, start int, count int) []hub.Thread

GetReposts returns a list with repost of a board thread. To reverse iterate use a negative count.

Open
OID
008ef3…d59e:16
GetReposts details

Inspect func

GetFlags

func(boardID uint64, threadID uint64, commentID uint64, start int, count int) []boards.Flag

GetFlag returns a list with thread or comment moderation flags. To reverse iterate use a negative count. Thread flags are returned when \`commentID\` is zero, or comment flags are returned otherwise.

Open
OID
008ef3…d59e:17
GetFlags details

Inspect func

GetComments

func(boardID uint64, threadID uint64, start int, count int) []hub.Comment

GetComments returns a list with all thread comments and replies. To reverse iterate use a negative count. Top level comments can be filtered by checking \`Comment.ParentID\`, replies always have a parent comment or reply, while comments have no parent.

Open
OID
008ef3…d59e:18
GetComments details

Inspect func

GetReplies

func(boardID uint64, threadID uint64, commentID uint64, start int, count int) []hub.Comment

GetReplies returns a list with top level comment replies. To reverse iterate use a negative count.

Open
OID
008ef3…d59e:19
GetReplies details

Inspect func

getBoard

func(int, rlm .uverse.realm, boardID uint64) (*boards.Board, bool)

getBoard fetches a raw \*boards.Board via boards2's protected GetBoard. Non-crossing helper: rlm is hub's own cur, threaded through from the enclosing crossing function.

Open
OID
008ef3…d59e:20
getBoard details

Inspect func

getThread

func(int, rlm .uverse.realm, boardID uint64, threadID uint64) (*boards.Post, bool)
Open
OID
008ef3…d59e:21
getThread details

Inspect func

getComment

func(int, rlm .uverse.realm, boardID uint64, threadID uint64, commentID uint64) (*boards.Post, bool)
Open
OID
008ef3…d59e:22
getComment details

Inspect func

Flag

type

Flag defines a type for thread and comment flags.

Value

hub.Flag

Thread

type

Thread defines a type for board threads.

Value

hub.Thread

NewSafeThread

func(ref *boards.Post) hub.Thread

NewSafeThread creates a safe thread.

Open
OID
008ef3…d59e:23
NewSafeThread details

Inspect func
Member : type =hub.Member
Board : type =hub.Board
NewSafeBoard : func(ref *boards.Board) hub.Board Inspect
Comment : type =hub.Comment
NewSafeComment : func(ref *boards.Post) hub.Comment Inspect
timeToUnix : func(t time.Time) int64 Inspect
GetBoard : func(id uint64) (hub.Board, bool) Inspect
GetThread : func(boardID uint64, threadID uint64) (hub.Thread, bool) Inspect
GetComment : func(boardID uint64, threadID uint64, commentID uint64) (hub.Comment, bool) Inspect
GetBoards : func(start int, count int) []hub.Board Inspect
GetThreads : func(boardID uint64, start int, count int) []hub.Thread Inspect
GetMembers : func(boardID uint64, start int, count int) []boards.User Inspect
GetReposts : func(boardID uint64, threadID uint64, start int, count int) []hub.Thread Inspect
GetFlags : func(boardID uint64, threadID uint64, commentID uint64, start int, count int) []boards.Flag Inspect
GetComments : func(boardID uint64, threadID uint64, start int, count int) []hub.Comment Inspect
GetReplies : func(boardID uint64, threadID uint64, commentID uint64, start int, count int) []hub.Comment Inspect
getBoard : func(int, rlm .uverse.realm, boardID uint64) (*boards.Board, bool) Inspect
getThread : func(int, rlm .uverse.realm, boardID uint64, threadID uint64) (*boards.Post, bool) Inspect
getComment : func(int, rlm .uverse.realm, boardID uint64, threadID uint64, commentID uint64) (*boards.Post, bool) Inspect
Flag : type =hub.Flag
Thread : type =hub.Thread
NewSafeThread : func(ref *boards.Post) hub.Thread Inspect