Documentation
¶
Index ¶
- Constants
- Variables
- func AwaitTime(seconds int, f func() bool) error
- func DebugSaveJson(filename string, data interface{}) error
- func GetCallerFunctionName() string
- func GetCurrentFunctionName() string
- type Account
- type Container
- type Element
- type HTTPClientError
- type HTTPServerError
- type Manager
- func (m *Manager) AddContact(firstName, lastName, walletAddress, publicKey string) ([]contact, error)
- func (m *Manager) AddSharedContainer(containerID string) error
- func (m *Manager) CancelObjectContext()
- func (m *Manager) ContainersChanged()
- func (m Manager) CopyToClipboard(txt string) error
- func (m *Manager) CreateContainer(name string, permission string, block bool) error
- func (m *Manager) DeleteContact(walletAddress string) ([]contact, error)
- func (m *Manager) DeleteContainer(id string) ([]Element, error)
- func (m *Manager) DeleteObject(objectID, containerID string) ([]Element, error)
- func (m *Manager) DeleteRecentWallet(walletId string) error
- func (m *Manager) DomReady(ctx context.Context)
- func (m *Manager) Download(filename, objectID, containerID string) error
- func (m *Manager) EnableCache(enable bool) error
- func (m *Manager) EnableLocalServer(enable bool)
- func (m *Manager) ForceSync()
- func (m *Manager) Get(objectID, containerID, fp string, writer io.Writer) ([]byte, error)
- func (m *Manager) GetAccountInformation() (Account, error)
- func (m *Manager) GetObjectMetaData(objectID, containerID string) (object.Object, error)
- func (m *Manager) GetVersion() string
- func (m *Manager) ListContainerIDs() ([]string, error)
- func (m *Manager) ListContainerObjects(containerID string, synchronised, deleted bool) ([]Element, error)
- func (m *Manager) ListContainers(synchronised, deleted bool) ([]Element, error)
- func (m *Manager) ListSharedContainerObjects(containerID string, synchronised bool) ([]Element, error)
- func (m *Manager) ListSharedContainers() ([]Element, error)
- func (m *Manager) LoadWallet(password string) error
- func (m *Manager) LoadWalletWithPath(password, filepath string) error
- func (m *Manager) LoadWalletWithoutPassword() (string, error)
- func (m *Manager) LockWallet()
- func (m *Manager) MakeNotification(message NotificationMessage)
- func (m *Manager) MakeToast(message UXMessage)
- func (m Manager) MarkAllNotificationsRead() error
- func (m Manager) MarkNotificationRead(uuid string) error
- func (m *Manager) NetworkChangeNotification()
- func (m *Manager) NewListReadOnlyContainerContents(since int64) ([]Element, error)
- func (m *Manager) NewWallet(password, filepath string) error
- func (m *Manager) NewWalletFromWIF(password, wif, filepath string) error
- func (m Manager) Notifications() ([]NotificationMessage, error)
- func (m Manager) OpenInDefaultBrowser(txt string) error
- func (m *Manager) Pool(forceRenew bool) (*pool.Pool, error)
- func (m *Manager) RecentWallets() (map[string]cleanedWallet, error)
- func (m *Manager) RemoveSharedContainer(containerId string) ([]Element, error)
- func (m *Manager) RestrictContainer(id string, publicKey string) error
- func (m *Manager) RetrieveContactByWalletAddress(walletAddress string) (contact, error)
- func (m *Manager) RetrieveContacts() ([]contact, error)
- func (m *Manager) RetrieveWIF() (string, error)
- func (m *Manager) SaveWalletWithoutPassword() (string, error)
- func (m *Manager) SendSignal(signalName string, signalValue interface{})
- func (m *Manager) SetProgressPercentage(progressMessage ProgressMessage)
- func (m *Manager) SetSelectedNetwork(network string) (NetworkData, error)
- func (m *Manager) SetWalletDebugging(walletPath, password string) error
- func (m *Manager) SetupServer(ctx context.Context) error
- func (m *Manager) Shutdown(ctx context.Context)
- func (m *Manager) Startup(ctx context.Context)
- func (m *Manager) TopUpNeoWallet(amount float64) (string, error)
- func (m *Manager) TransferToken(recipient string, amount float64) (string, error)
- func (m *Manager) UnlockWallet() error
- func (m *Manager) Upload(containerID string, attributes map[string]string) ([]Element, error)
- func (m *Manager) UploadObject(containerID, fp string, filtered map[string]string) ([]Element, error)
- type Mimes
- type Network
- type NetworkData
- type NodeSelection
- type NotificationMessage
- type ProgressMessage
- type TmpObjectMeta
- type UXMessage
Constants ¶
const (
CACHE_FILE_SYSTEM = "filesystem"
)
Variables ¶
var NotFound = errors.New("wallet not found")
Functions ¶
func DebugSaveJson ¶
func GetCallerFunctionName ¶
func GetCallerFunctionName() string
func GetCurrentFunctionName ¶
func GetCurrentFunctionName() string
Types ¶
type Element ¶
type Element struct { ID string `json:"id"` Type string `josn:"type"` Size uint64 `json:"size"` BasicAcl acl.Basic ExtendedAcl eacl.Table Attributes map[string]string `json:"attributes""` Errors []error `json:"errors",omitempty` ParentID string Children []Element `json:"children",omitempty` PendingDeleted bool }
type HTTPClientError ¶
type HTTPClientError struct { Code int `json:"code" example:"400"` Message string `json:"message" example:"status bad request"` }
HTTPClientError returned when a client error occurs
type HTTPServerError ¶
type HTTPServerError struct { Code int `json:"code" example:"502"` Message string `json:"message" example:"status server error"` }
HTTPServerError returned when a server error occurs
type Manager ¶
type Manager struct { DEBUG bool // contains filtered or unexported fields }
func NewFileSystemManager ¶
func (*Manager) AddContact ¶
func (*Manager) AddSharedContainer ¶
func (*Manager) CancelObjectContext ¶ added in v0.5.7
func (m *Manager) CancelObjectContext()
func (*Manager) ContainersChanged ¶
func (m *Manager) ContainersChanged()
func (Manager) CopyToClipboard ¶
func (*Manager) CreateContainer ¶
func (*Manager) DeleteContact ¶
func (*Manager) DeleteContainer ¶
DeleteContainer must mark the container in the cache as deleted and delete it from neoFS
func (*Manager) DeleteObject ¶
func (*Manager) DeleteRecentWallet ¶
func (*Manager) Download ¶
Upload will put an object in NeoFS. You can access publically available files at https://http.testnet.fs.neo.org/<containerID>/<objectID>
func (*Manager) EnableCache ¶
func (*Manager) EnableLocalServer ¶
func (*Manager) GetAccountInformation ¶
func (*Manager) GetObjectMetaData ¶
GetObjectMetaData is live not cached
func (*Manager) GetVersion ¶
func (*Manager) ListContainerIDs ¶
func (*Manager) ListContainerObjects ¶
func (m *Manager) ListContainerObjects(containerID string, synchronised, deleted bool) ([]Element, error)
ListContainerObjects ets from cache
func (*Manager) ListContainers ¶
ListContainers populates from cache
func (*Manager) ListSharedContainerObjects ¶
func (m *Manager) ListSharedContainerObjects(containerID string, synchronised bool) ([]Element, error)
ListSharedContainerObjects ets from cache
func (*Manager) ListSharedContainers ¶
func (*Manager) LoadWallet ¶
func (*Manager) LoadWalletWithPath ¶
func (*Manager) LoadWalletWithoutPassword ¶
firstly call this to get a filepath then once the filepath is returned to the frontend, call the modal to get a password then finally from the frontend call return m.LoadWalletWithPath(password, filepath) wallet loaded.
func (*Manager) LockWallet ¶
func (m *Manager) LockWallet()
func (*Manager) MakeNotification ¶
func (m *Manager) MakeNotification(message NotificationMessage)
func (Manager) MarkAllNotificationsRead ¶
func (Manager) MarkNotificationRead ¶
func (*Manager) NetworkChangeNotification ¶
func (m *Manager) NetworkChangeNotification()
func (*Manager) NewListReadOnlyContainerContents ¶
NewListReadOnlyContainerContents lists from cache
func (*Manager) NewWalletFromWIF ¶
func (Manager) Notifications ¶
func (m Manager) Notifications() ([]NotificationMessage, error)
func (Manager) OpenInDefaultBrowser ¶
func (*Manager) Pool ¶
todo we will want to have things dependent on the wallet controlled elsewhere with singletons and no other way of getting the value todo remove the need to pass the private key to the api (usually for getOwnerID - however this should be passed into the backend
func (*Manager) RecentWallets ¶
func (*Manager) RemoveSharedContainer ¶
func (*Manager) RestrictContainer ¶
func (*Manager) RetrieveContactByWalletAddress ¶
func (*Manager) RetrieveContacts ¶
func (*Manager) RetrieveWIF ¶
func (*Manager) SaveWalletWithoutPassword ¶
firstly call this to get a filepath then once the filepath is returned to the frontend, call the modal to get a password then finally from the frontend call return m.LoadWalletWithPath(password, filepath) wallet loaded.
func (*Manager) SendSignal ¶
func (*Manager) SetProgressPercentage ¶
func (m *Manager) SetProgressPercentage(progressMessage ProgressMessage)
func (*Manager) SetSelectedNetwork ¶
func (m *Manager) SetSelectedNetwork(network string) (NetworkData, error)
return the network addresses for the selected network
func (*Manager) SetWalletDebugging ¶
func (*Manager) TopUpNeoWallet ¶
todo - terrible name if this is to topup NeoFS Gas
func (*Manager) TransferToken ¶
func (*Manager) UnlockWallet ¶
func (*Manager) Upload ¶
Upload will put an object in NeoFS. You can access publically available files at https://http.testnet.fs.neo.org/<containerID>/<objectID>
type NetworkData ¶
type NodeSelection ¶ added in v0.5.7
func NewNetworkSelector ¶ added in v0.5.7
func NewNetworkSelector(nodes []config.Peer) NodeSelection
type NotificationMessage ¶
type NotificationMessage struct { Id string User string //who is this message for so we can store it in the database Title string Type string Action string Description string Meta map[string]string CreatedAt string MarkRead bool }
func NewNotificationMessage ¶
func NewNotificationMessage(p *NotificationMessage) NotificationMessage
type ProgressMessage ¶
func NewProgressMessage ¶
func NewProgressMessage(p *ProgressMessage) ProgressMessage