Documentation
¶
Index ¶
- Constants
- type AdminConfig
- type AuthConfig
- type BaseConfig
- type BaseConfigExtracter
- type BlogConfig
- type ForumConfig
- type LocalesConfig
- type LoginConfig
- type ProfileConfig
- type RemoteWidgetConfig
- type ServiceConfig
- type SessionConfig
- type SettingsConfig
- type SiteConfig
- type TemplateConfig
- type WikiConfig
Constants ¶
View Source
const ( WebKey = "puzzleWeb" DefaultFavicon = "/favicon.ico" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminConfig ¶
type AdminConfig struct {
ServiceConfig[adminservice.AdminService]
UserService loginservice.AdvancedUserService
ProfileService profileservice.AdvancedProfileService
PageSize uint64
}
type AuthConfig ¶
type AuthConfig = ServiceConfig[adminservice.AuthService]
type BaseConfig ¶
type BaseConfig interface {
GetLogger() log.Logger
GetLoggerGetter() log.LoggerGetter
}
type BaseConfigExtracter ¶
type BaseConfigExtracter interface {
BaseConfig
GetServiceTimeOut() time.Duration
ExtractLocalesConfig() LocalesConfig
ExtractLoginConfig() LoginConfig
ExtractAdminConfig() AdminConfig
ExtractSettingsConfig() SettingsConfig
ExtractProfileConfig() ProfileConfig
}
type BlogConfig ¶
type BlogConfig struct {
ServiceConfig[blogservice.BlogService]
MarkdownService markdownservice.MarkdownService
CommentService forumservice.CommentService
Domain string
Port string
DateFormat string
PageSize uint64
ExtractSize uint64
FeedFormat string
FeedSize uint64
Args []string
}
type ForumConfig ¶
type ForumConfig struct {
ServiceConfig[forumservice.ForumService]
PageSize uint64
Args []string
}
type LocalesConfig ¶
type LoginConfig ¶
type LoginConfig = ServiceConfig[loginservice.LoginService]
type ProfileConfig ¶
type ProfileConfig struct {
ServiceConfig[profileservice.AdvancedProfileService]
AdminService adminservice.AdminService
LoginService loginservice.FullLoginService
}
type RemoteWidgetConfig ¶
type RemoteWidgetConfig = ServiceConfig[widgetservice.WidgetService]
type ServiceConfig ¶
type ServiceConfig[ServiceType any] struct { Logger log.Logger // for init phase (have the context) LoggerGetter log.LoggerGetter Service ServiceType }
func MakeServiceConfig ¶
func MakeServiceConfig[ServiceType any](c BaseConfig, service ServiceType) ServiceConfig[ServiceType]
func (*ServiceConfig[ServiceType]) GetLogger ¶
func (c *ServiceConfig[ServiceType]) GetLogger() log.Logger
func (*ServiceConfig[ServiceType]) GetLoggerGetter ¶ added in v1.10.4
func (c *ServiceConfig[ServiceType]) GetLoggerGetter() log.LoggerGetter
type SessionConfig ¶
type SessionConfig struct {
ServiceConfig[sessionservice.SessionService]
Domain string
TimeOut int
}
type SettingsConfig ¶
type SettingsConfig = ServiceConfig[sessionservice.SessionService]
type SiteConfig ¶
type SiteConfig struct {
ServiceConfig[sessionservice.SessionService]
TemplateService templateservice.TemplateService
Domain string
Port string
SessionTimeOut int
MaxMultipartMemory int64
StaticFileSystem http.FileSystem
FaviconPath string
Page404Url string
LangPicturePaths map[string]string
}
func (*SiteConfig) ExtractSessionConfig ¶
func (sc *SiteConfig) ExtractSessionConfig() SessionConfig
func (*SiteConfig) ExtractTemplateConfig ¶
func (sc *SiteConfig) ExtractTemplateConfig() TemplateConfig
type TemplateConfig ¶
type TemplateConfig = ServiceConfig[templateservice.TemplateService]
type WikiConfig ¶
type WikiConfig struct {
ServiceConfig[wikiservice.WikiService]
MarkdownService markdownservice.MarkdownService
Args []string
}
Click to show internal directories.
Click to hide internal directories.