2024-04-19 05:12:56 +00:00
|
|
|
package dpp
|
|
|
|
|
|
|
|
import (
|
|
|
|
"git.kirsle.net/SketchyMaze/doodle/pkg/doodads"
|
|
|
|
"git.kirsle.net/SketchyMaze/doodle/pkg/filesystem"
|
|
|
|
"git.kirsle.net/SketchyMaze/doodle/pkg/level"
|
|
|
|
"git.kirsle.net/SketchyMaze/doodle/pkg/levelpack"
|
|
|
|
"git.kirsle.net/SketchyMaze/doodle/pkg/plus"
|
|
|
|
)
|
|
|
|
|
2024-04-19 05:49:12 +00:00
|
|
|
// Driver is the currently installed Doodle++ implementation (FOSS or DPP).
|
2024-04-19 05:12:56 +00:00
|
|
|
var Driver Pluggable
|
|
|
|
|
2024-04-19 05:49:12 +00:00
|
|
|
// Pluggable defines the interface for Doodle++ functions, so that their implementations
|
|
|
|
// can avoid cyclic dependency errors. Documentation for these functions is only spelled
|
|
|
|
// out in the SketchyMaze/dpp package.
|
2024-04-19 05:12:56 +00:00
|
|
|
type Pluggable interface {
|
|
|
|
LoadFromEmbeddable(string, filesystem.Embeddable, bool) (*doodads.Doodad, error)
|
|
|
|
IsRegistered() bool
|
|
|
|
GetRegistration() (plus.Registration, error)
|
|
|
|
UploadLicenseFile(string) (plus.Registration, error)
|
|
|
|
IsLevelSigned(*level.Level) bool
|
|
|
|
IsLevelPackSigned(*levelpack.LevelPack) bool
|
|
|
|
}
|