Documentation ¶
Index ¶
Constants ¶
View Source
const (
// ProductName is the product name.
ProductName = "puzzledb"
)
View Source
const (
Version = "v0.8.0"
)
Variables ¶
View Source
var ErrNotFound = errors.New("not found")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config interface { // Get returns a value for the specified name. Get(name ...string) (any, error) // GetString returns a string value for the specified name. GetString(name ...string) (string, error) // GetInt returns an integer value for the specified name. GetInt(name ...string) (int, error) // String returns a string representation of the configuration. String() string }
Config represents a configuration interface.
func NewConfigWithPath ¶
NewConfigWithPath returns a new configuration with the specified path.
func NewConfigWithString ¶
NewConfigWithString returns a new configuration with the specified string.
type Server ¶
type Server struct { *ServerConfig *plugins.Manager }
Server represents a server instance.
func NewServerWithConfig ¶
NewServerWithConfig returns a new server instance with the specified configuration.
func (*Server) LoadPlugins ¶
type ServerConfig ¶
type ServerConfig struct {
Config
}
func NewServerConfigWith ¶
func NewServerConfigWith(config Config) *ServerConfig
func (*ServerConfig) Port ¶
func (conf *ServerConfig) Port(name string) (int, error)
Port returns a port number for the specified name.
func (*ServerConfig) String ¶
func (conf *ServerConfig) String() string
Source Files ¶
Click to show internal directories.
Click to hide internal directories.