Documentation ¶
Index ¶
- Constants
- func GetMapOfHttpStatusCodesByRpcErrorCodes() map[int]int
- type Server
- func (srv *Server) AddForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) AddMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) AddSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) AddThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeForumName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeForumSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeMessageText(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeMessageThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeSectionName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeSectionParent(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeThreadForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ChangeThreadName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) DeleteForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) DeleteMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) DeleteSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) DeleteThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetDKey(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetLatestMessageOfThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetListenDsn() (dsn string)
- func (srv *Server) GetMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetMustStopAB() *atomic.Bool
- func (srv *Server) GetSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) GetStopChannel() *chan bool
- func (srv *Server) GetSubRoutinesWG() *sync.WaitGroup
- func (srv *Server) GetThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ListForumAndThreads(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ListForumAndThreadsOnPage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ListSectionsAndForums(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ListThreadAndMessages(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ListThreadAndMessagesOnPage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveForumDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveForumUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveSectionDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveSectionUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveThreadDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) MoveThreadUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) Ping(_ *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ReportStart()
- func (srv *Server) ShowDiagnosticData(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) Start() (err error)
- func (srv *Server) Stop() (err error)
- func (srv *Server) Test(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) ThreadExistsS(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
- func (srv *Server) UseConstructor(stn cm.ISettings) (cm.IServer, error)
Constants ¶
View Source
const ( RpcErrorCode_SectionNameIsNotSet = 1 RpcErrorCode_RootSectionAlreadyExists = 2 RpcErrorCode_SectionIsNotFound = 3 RpcErrorCode_SectionIdIsNotSet = 4 RpcErrorCode_SectionHasChildren = 5 RpcErrorCode_RootSectionCanNotBeMoved = 6 RpcErrorCode_ForumNameIsNotSet = 7 RpcErrorCode_ForumIsNotFound = 8 RpcErrorCode_ForumIdIsNotSet = 9 RpcErrorCode_ForumHasThreads = 10 RpcErrorCode_ThreadNameIsNotSet = 11 RpcErrorCode_ThreadIdIsNotSet = 12 RpcErrorCode_ThreadIsNotFound = 13 RpcErrorCode_ThreadIsNotEmpty = 14 RpcErrorCode_MessageTextIsNotSet = 15 RpcErrorCode_MessageIdIsNotSet = 16 RpcErrorCode_IncompatibleChildType = 17 RpcErrorCode_MessageIsNotFound = 18 RpcErrorCode_PageIsNotSet = 19 RpcErrorCode_TestError = 20 )
Codes.
View Source
const ( RpcErrorMsg_SectionNameIsNotSet = "section name is not set" RpcErrorMsg_RootSectionAlreadyExists = "root section already exists" RpcErrorMsg_SectionIsNotFound = "section is not found" RpcErrorMsg_SectionIdIsNotSet = "section ID is not set" RpcErrorMsg_SectionHasChildren = "section has children" RpcErrorMsg_RootSectionCanNotBeMoved = "root section can not be moved" RpcErrorMsg_ForumNameIsNotSet = "forum name is not set" RpcErrorMsg_ForumIsNotFound = "forum is not found" RpcErrorMsg_ForumIdIsNotSet = "forum ID is not set" RpcErrorMsg_ForumHasThreads = "forum has threads" RpcErrorMsg_ThreadNameIsNotSet = "thread name is not set" RpcErrorMsg_ThreadIdIsNotSet = "thread ID is not set" RpcErrorMsg_ThreadIsNotFound = "thread is not found" RpcErrorMsg_ThreadIsNotEmpty = "thread is not empty" RpcErrorMsg_MessageTextIsNotSet = "message text is not set" RpcErrorMsg_MessageIdIsNotSet = "message ID is not set" RpcErrorMsg_IncompatibleChildType = "incompatible child type" RpcErrorMsg_MessageIsNotFound = "message is not found" RpcErrorMsg_PageIsNotSet = "page is not set" RpcErrorMsgF_TestError = "test error: %s" )
Messages.
Variables ¶
This section is empty.
Functions ¶
func GetMapOfHttpStatusCodesByRpcErrorCodes ¶
Unique HTTP status codes used in the map: - 400 (Bad request); - 404 (Not found); - 409 (Conflict); - 500 (Internal server error).
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) AddForum ¶
func (srv *Server) AddForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) AddMessage ¶
func (srv *Server) AddMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) AddSection ¶
func (srv *Server) AddSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) AddThread ¶
func (srv *Server) AddThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeForumName ¶
func (srv *Server) ChangeForumName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeForumSection ¶
func (srv *Server) ChangeForumSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeMessageText ¶
func (srv *Server) ChangeMessageText(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeMessageThread ¶
func (srv *Server) ChangeMessageThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeSectionName ¶
func (srv *Server) ChangeSectionName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeSectionParent ¶
func (srv *Server) ChangeSectionParent(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeThreadForum ¶
func (srv *Server) ChangeThreadForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ChangeThreadName ¶
func (srv *Server) ChangeThreadName(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) DeleteForum ¶
func (srv *Server) DeleteForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) DeleteMessage ¶
func (srv *Server) DeleteMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) DeleteSection ¶
func (srv *Server) DeleteSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) DeleteThread ¶
func (srv *Server) DeleteThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetDKey ¶ added in v0.0.45
func (srv *Server) GetDKey(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetForum ¶
func (srv *Server) GetForum(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetLatestMessageOfThread ¶ added in v0.0.44
func (srv *Server) GetLatestMessageOfThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetListenDsn ¶
func (*Server) GetMessage ¶
func (srv *Server) GetMessage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetMustStopAB ¶ added in v0.0.40
func (*Server) GetSection ¶
func (srv *Server) GetSection(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) GetStopChannel ¶
func (*Server) GetSubRoutinesWG ¶ added in v0.0.40
func (*Server) GetThread ¶
func (srv *Server) GetThread(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ListForumAndThreads ¶
func (srv *Server) ListForumAndThreads(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ListForumAndThreadsOnPage ¶
func (srv *Server) ListForumAndThreadsOnPage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ListSectionsAndForums ¶
func (srv *Server) ListSectionsAndForums(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ListThreadAndMessages ¶
func (srv *Server) ListThreadAndMessages(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ListThreadAndMessagesOnPage ¶
func (srv *Server) ListThreadAndMessagesOnPage(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveForumDown ¶ added in v0.0.38
func (srv *Server) MoveForumDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveForumUp ¶ added in v0.0.38
func (srv *Server) MoveForumUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveSectionDown ¶ added in v0.0.38
func (srv *Server) MoveSectionDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveSectionUp ¶ added in v0.0.38
func (srv *Server) MoveSectionUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveThreadDown ¶ added in v0.0.38
func (srv *Server) MoveThreadDown(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) MoveThreadUp ¶ added in v0.0.38
func (srv *Server) MoveThreadUp(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) Ping ¶
func (srv *Server) Ping(_ *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ReportStart ¶
func (srv *Server) ReportStart()
func (*Server) ShowDiagnosticData ¶
func (srv *Server) ShowDiagnosticData(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) Test ¶
func (srv *Server) Test(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
func (*Server) ThreadExistsS ¶ added in v0.0.45
func (srv *Server) ThreadExistsS(params *json.RawMessage, _ *jrm1.ResponseMetaData) (result any, re *jrm1.RpcError)
Click to show internal directories.
Click to hide internal directories.