Documentation ¶
Index ¶
- func InitRepo(config *InitConfig) error
- func MigrateRepo(config *MigrateConfig) error
- func NewWallet(wordCount int) (string, error)
- func WalletAccountAt(phrase string, index int, password string) (string, error)
- type Callback
- type Event
- type ExternalInvite
- type FileData
- type InitConfig
- type Messenger
- type MigrateConfig
- type Mobile
- func (m *Mobile) AcceptExternalThreadInvite(id string, key string) (string, error)
- func (m *Mobile) AcceptThreadInviteViaNotification(id string) (string, error)
- func (m *Mobile) AddContact(id string, address string, username string) error
- func (m *Mobile) AddExternalThreadInvite(threadId string) (string, error)
- func (m *Mobile) AddPeerToThread(id string, threadId string) error
- func (m *Mobile) AddSchema(jsonstr string) (string, error)
- func (m *Mobile) AddThread(key string, name string) (string, error)
- func (m *Mobile) AddThreadComment(blockId string, body string) (string, error)
- func (m *Mobile) AddThreadFiles(dir []byte, threadId string, caption string) (string, error)
- func (m *Mobile) AddThreadFilesByTarget(target string, threadId string, caption string) (string, error)
- func (m *Mobile) AddThreadIgnore(blockId string) (string, error)
- func (m *Mobile) AddThreadInvite(threadId string, inviteeId string) (string, error)
- func (m *Mobile) AddThreadLike(blockId string) (string, error)
- func (m *Mobile) Address() string
- func (m *Mobile) CafeSession(peerId string) (string, error)
- func (m *Mobile) CafeSessions() (string, error)
- func (m *Mobile) CheckCafeMessages() error
- func (m *Mobile) Contact(id string) (string, error)
- func (m *Mobile) ContactThreads(id string) (string, error)
- func (m *Mobile) ContactUsername(id string) string
- func (m *Mobile) Contacts() (string, error)
- func (m *Mobile) CountUnreadNotifications() int
- func (m *Mobile) DeregisterCafe(peerId string) error
- func (m *Mobile) FileData(hash string) (string, error)
- func (m *Mobile) IgnoreThreadInviteViaNotification(id string) error
- func (m *Mobile) ImageFileDataForMinWidth(pth string, minWidth int) (string, error)
- func (m *Mobile) Notifications(offset string, limit int) (string, error)
- func (m *Mobile) OnlineCh() <-chan struct{}
- func (m *Mobile) Overview() (string, error)
- func (m *Mobile) PeerId() (string, error)
- func (m *Mobile) PeerProfile(peerId string) (string, error)
- func (m *Mobile) PrepareFiles(path string, threadId string) ([]byte, error)
- func (m *Mobile) PrepareFilesAsync(path string, threadId string, cb Callback)
- func (m *Mobile) Profile() (string, error)
- func (m *Mobile) ReadAllNotifications() error
- func (m *Mobile) ReadNotification(id string) error
- func (m *Mobile) RefreshCafeSession(peerId string) (string, error)
- func (m *Mobile) RegisterCafe(peerId string) error
- func (m *Mobile) RemoveThread(id string) (string, error)
- func (m *Mobile) Seed() string
- func (m *Mobile) SetAvatar(hash string) error
- func (m *Mobile) SetUsername(username string) error
- func (m *Mobile) Start() error
- func (m *Mobile) Stop() error
- func (m *Mobile) ThreadFiles(offset string, limit int, threadId string) (string, error)
- func (m *Mobile) ThreadInfo(threadId string) (string, error)
- func (m *Mobile) Threads() (string, error)
- func (m *Mobile) Username() (string, error)
- func (m *Mobile) Version() string
- type RunConfig
- type WalletAccount
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ExternalInvite ¶
type ExternalInvite struct { Id string `json:"id"` Key string `json:"key"` Inviter string `json:"inviter"` }
ExternalInvite is a wrapper around an invite id and key
type FileData ¶
type FileData struct {
Url string `json:"url"`
}
FileData is a wrapper around a file data url
type InitConfig ¶
InitConfig is used to setup a textile node
type Messenger ¶
type Messenger interface {
Notify(event *Event)
}
Messenger is used to inform the bridge layer of new data waiting to be queried
type MigrateConfig ¶
type MigrateConfig struct {
RepoPath string
}
MigrateConfig is used to define options during a major migration
type Mobile ¶
type Mobile struct { RepoPath string // contains filtered or unexported fields }
Mobile is the name of the framework (must match package name)
func NewTextile ¶
Create a gomobile compatible wrapper around Textile
func (*Mobile) AcceptExternalThreadInvite ¶
AcceptExternalThreadInvite notifies the thread of a join
func (*Mobile) AcceptThreadInviteViaNotification ¶
AcceptThreadInviteViaNotification call core AcceptThreadInviteViaNotification
func (*Mobile) AddContact ¶
AddContact calls core AddContact
func (*Mobile) AddExternalThreadInvite ¶
AddExternalThreadInvite generates a new external invite link to a thread
func (*Mobile) AddPeerToThread ¶
AddPeerToThread call thread AddPeer
func (*Mobile) AddThreadComment ¶
AddThreadComment adds a comment targeted at the given block
func (*Mobile) AddThreadFiles ¶
AddThreadFiles adds a prepared file to a thread
func (*Mobile) AddThreadFilesByTarget ¶
func (m *Mobile) AddThreadFilesByTarget(target string, threadId string, caption string) (string, error)
AddThreadFilesByTarget adds a prepared file to a thread by referencing its top level hash
func (*Mobile) AddThreadIgnore ¶
AddThreadIgnore adds an ignore targeted at the given block and unpins any associated target data
func (*Mobile) AddThreadInvite ¶
AddThreadInvite adds a new invite to a thread
func (*Mobile) AddThreadLike ¶
AddThreadLike adds a like targeted at the given block
func (*Mobile) CafeSession ¶
CafeSession calls core CafeSession
func (*Mobile) CafeSessions ¶
CafeSessions calls core CafeSessions
func (*Mobile) CheckCafeMessages ¶
CheckCafeMessages calls core CheckCafeMessages
func (*Mobile) ContactThreads ¶
ContactThreads calls core ContactThreads
func (*Mobile) ContactUsername ¶
ContactUsername calls core ContactUsername
func (*Mobile) CountUnreadNotifications ¶
CountUnreadNotifications calls core CountUnreadNotifications
func (*Mobile) DeregisterCafe ¶
DeegisterCafe calls core DeregisterCafe
func (*Mobile) IgnoreThreadInviteViaNotification ¶
IgnoreThreadInviteViaNotification call core IgnoreThreadInviteViaNotification
func (*Mobile) ImageFileDataForMinWidth ¶
ImageFileDataForMinWidth returns a data url of an image at or above requested size, or the next best option. Note: Now that consumers are in control of image sizes via schemas, handling this here doesn't feel right. We can eventually push this up to RN, Obj-C, Java. Note: pth is <target>/<index>, e.g., "Qm.../0"
func (*Mobile) Notifications ¶
Notifications call core Notifications
func (*Mobile) OnlineCh ¶
func (m *Mobile) OnlineCh() <-chan struct{}
OnlineCh returns core OnlineCh
func (*Mobile) PeerProfile ¶
PeerProfile looks up a profile by id
func (*Mobile) PrepareFiles ¶
PrepareFiles processes a file by path for a thread, but does NOT share it
func (*Mobile) PrepareFilesAsync ¶
PrepareFilesAsync is the async flavor of PrepareFiles
func (*Mobile) ReadAllNotifications ¶
ReadAllNotifications calls core ReadAllNotifications
func (*Mobile) ReadNotification ¶
ReadNotification calls core ReadNotification
func (*Mobile) RefreshCafeSession ¶
RefreshCafeSession calls core RefreshCafeSession
func (*Mobile) RegisterCafe ¶
RegisterCafe calls core RegisterCafe
func (*Mobile) RemoveThread ¶
RemoveThread call core RemoveThread
func (*Mobile) SetUsername ¶
SetUsername calls core SetUsername
func (*Mobile) ThreadFiles ¶
ThreadFiles calls core ThreadFiles
func (*Mobile) ThreadInfo ¶
ThreadInfo calls core ThreadInfo
type RunConfig ¶
type RunConfig struct {
RepoPath string
}
RunConfig is used to define run options for a mobile node
type WalletAccount ¶
WalletAccount represents a derived account in a wallet