app

package
v0.0.63 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2024 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrServiceName                  = "service name error"
	ErrConfigurationFilePathDefault = "default configuration file path error"
)
View Source
const (
	ServiceName_ACM  = "Access Control Module"
	ServiceName_GWM  = "Gateway Module"
	ServiceName_MM   = "Message Module"
	ServiceName_NM   = "Notification Module"
	ServiceName_RCS  = "Captcha Module"
	ServiceName_SM   = "Subscription Module"
	ServiceName_SMTP = "SMTP Module"
)
View Source
const (
	ConfigurationFilePathDefault_ACM  = "ACM.json"
	ConfigurationFilePathDefault_GWM  = "GWM.json"
	ConfigurationFilePathDefault_MM   = "MM.json"
	ConfigurationFilePathDefault_NM   = "NM.json"
	ConfigurationFilePathDefault_RCS  = "RCS.json"
	ConfigurationFilePathDefault_SM   = "SM.json"
	ConfigurationFilePathDefault_SMTP = "SMTP.json"
)
View Source
const (
	ServiceShortName_ACM  = "ACM"
	ServiceShortName_GWM  = "GWM"
	ServiceShortName_MM   = "MM"
	ServiceShortName_NM   = "NM"
	ServiceShortName_RCS  = "RCS"
	ServiceShortName_SM   = "SM"
	ServiceShortName_SMTP = "SMTP"
)
View Source
const (
	ModuleId_ACM  = cm.Module_ACM
	ModuleId_GWM  = cm.Module_GWM
	ModuleId_MM   = cm.Module_MM
	ModuleId_NM   = cm.Module_NM
	ModuleId_RCS  = cm.Module_RCS
	ModuleId_SM   = cm.Module_SM
	ModuleId_SMTP = cm.Module_SMTP
)

Variables

This section is empty.

Functions

func NewServer

func NewServer[T cm.IServer](classSelector T, settings cm.ISettings) (srv cm.IServer, err error)

func NewSettingsFromFile

func NewSettingsFromFile[T cm.ISettings](classSelector T, filePath string, versionInfo *ver.Versioneer) (stn cm.ISettings, err error)

Types

type Application

type Application struct {
	// contains filtered or unexported fields
}

func NewApplication

func NewApplication[T1 cm.ISettings, T2 cm.IServer](
	settingsClassSelector T1,
	serverClassSelector T2,
	serviceName string,
	configurationFilePathDefault string,
) (a *Application, err error)

func (*Application) Use

func (a *Application) Use() (err error)

type CommandLineArguments

type CommandLineArguments struct {
	// contains filtered or unexported fields
}

func NewCommandLineArgumentsFromOsArgs

func NewCommandLineArgumentsFromOsArgs(osArgs []string, defaultCfgFilePath string) (cla *CommandLineArguments, err error)

func (*CommandLineArguments) GetConfigurationFilePath

func (cla *CommandLineArguments) GetConfigurationFilePath() string

func (*CommandLineArguments) IsDefaultFile

func (cla *CommandLineArguments) IsDefaultFile() (isDefaultFile bool)

IsDefaultFile tells whether the default file path is used for the configuration file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL