Some checks failed
Build & Sign Wraith / Build Windows + Sign (push) Has been cancelled
Go + Wails v3 + Vue 3 + SQLite + FreeRDP3 (purego) 183 tests, 76 source files, 9,910 lines of code Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
58 lines
1.4 KiB
Go
58 lines
1.4 KiB
Go
package plugin
|
|
|
|
type ProtocolHandler interface {
|
|
Name() string
|
|
Connect(config map[string]interface{}) (Session, error)
|
|
Disconnect(sessionID string) error
|
|
}
|
|
|
|
type Session interface {
|
|
ID() string
|
|
Protocol() string
|
|
Write(data []byte) error
|
|
Close() error
|
|
}
|
|
|
|
type Importer interface {
|
|
Name() string
|
|
FileExtensions() []string
|
|
Parse(data []byte) (*ImportResult, error)
|
|
}
|
|
|
|
type ImportResult struct {
|
|
Groups []ImportGroup `json:"groups"`
|
|
Connections []ImportConnection `json:"connections"`
|
|
HostKeys []ImportHostKey `json:"hostKeys"`
|
|
Theme *ImportTheme `json:"theme,omitempty"`
|
|
}
|
|
|
|
type ImportGroup struct {
|
|
Name string `json:"name"`
|
|
ParentName string `json:"parentName,omitempty"`
|
|
}
|
|
|
|
type ImportConnection struct {
|
|
Name string `json:"name"`
|
|
Hostname string `json:"hostname"`
|
|
Port int `json:"port"`
|
|
Protocol string `json:"protocol"`
|
|
Username string `json:"username"`
|
|
GroupName string `json:"groupName"`
|
|
Notes string `json:"notes"`
|
|
}
|
|
|
|
type ImportHostKey struct {
|
|
Hostname string `json:"hostname"`
|
|
Port int `json:"port"`
|
|
KeyType string `json:"keyType"`
|
|
Fingerprint string `json:"fingerprint"`
|
|
}
|
|
|
|
type ImportTheme struct {
|
|
Name string `json:"name"`
|
|
Foreground string `json:"foreground"`
|
|
Background string `json:"background"`
|
|
Cursor string `json:"cursor"`
|
|
Colors [16]string `json:"colors"`
|
|
}
|