rpc

package
v0.0.0-...-9835270 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2021 License: AGPL-3.0, Apache-2.0, MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Download

func Download(
	cfg *config.Dendrite,
	rpcCli *common.RpcClient,
	id, destination, mediaID, width, method, fileType string,
) (io.Reader, int, http.Header, error)

func GetAliasRoomID

func GetAliasRoomID(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetDirectoryRoomAliasRequest,
	response *external.GetDirectoryRoomAliasResponse,
) error

func GetAvatar

func GetAvatar(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetProfileRequest,
	response *external.GetAvatarURLResponse,
) error

func GetDisplayName

func GetDisplayName(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetProfileRequest,
	response *external.GetDisplayNameResponse,
) error

func GetProfile

func GetProfile(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetProfileRequest,
	response *external.GetProfileResponse,
) error

func GetRoomState

func GetRoomState(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetFedRoomStateRequest,
	response *gomatrixserverlib.RespState,
) error

func GetUserInfo

func GetUserInfo(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	req *external.GetUserInfoRequest,
	response *external.GetUserInfoResponse,
) error

func MakeJoin

func MakeJoin(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	roomID, userID string, ver []string,
	response *gomatrixserverlib.RespMakeJoin,
) error

func MakeLeave

func MakeLeave(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	roomID, userID string,
	response *gomatrixserverlib.RespMakeLeave,
) error

func RpcRequest

func RpcRequest(
	rpcClient *common.RpcClient,
	destination, topic string,
	request interface{},
) ([]byte, error)

func SendInvite

func SendInvite(
	cfg *config.Dendrite,
	rpcCli *common.RpcClient,
	destination string,
	event gomatrixserverlib.Event,
	response *gomatrixserverlib.RespInvite,
) error

func SendJoin

func SendJoin(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	roomID, eventID string,
	event gomatrixserverlib.Event,
	resp *gomatrixserverlib.RespSendJoin,
) error

func SendLeave

func SendLeave(
	cfg *config.Dendrite,
	rpcClient *common.RpcClient,
	destination string,
	roomID, eventID string,
	event gomatrixserverlib.Event,
	resp *gomatrixserverlib.RespSendLeave,
) error

Types

type DownloadCB

type DownloadCB struct {
	// contains filtered or unexported fields
}

func (*DownloadCB) Clean

func (cb *DownloadCB) Clean()

func (*DownloadCB) GetCB

func (*DownloadCB) GetTopic

func (cb *DownloadCB) GetTopic() string

type DownloadReader

type DownloadReader struct {
	// contains filtered or unexported fields
}

func (*DownloadReader) Read

func (r *DownloadReader) Read(p []byte) (n int, err error)

type RpcResponse

type RpcResponse struct {
	Error   string
	Payload jsoniter.RawMessage
}

Jump to

Keyboard shortcuts

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