func (c *Config) Render() (string, error) {
	c.Lock()
	defer c.Unlock()
	funcMap := template.FuncMap{
		// This function will be called by the html/template engine that will perform HTML escaping of quotes characters in the output string
		"getJSONSyslogFormat": func(name string) string {
			return `{"agent":"` + strings.ToLower(name) + `","level":"%LEVEL","relfile":"%ShortFilePath","line":"%Line","msg":"%Msg"%ExtraJSONContext}%n`
		},
	}
	tmpl, err := template.New("seelog_config").Funcs(funcMap).Parse(seelogConfigurationTemplate)
	if err != nil {
		return "", err
	}
	b := &bytes.Buffer{}
	err = tmpl.Execute(b, c.settings)
	return b.String(), err
}
// Render generates a string containing a valid seelog XML configuration
Render generates a string containing a valid seelog XML configuration
// Render generates a string containing a valid seelog XML configuration
func (c *Config) Render() (string, error) {
	c.Lock()
	defer c.Unlock()
	funcMap := template.FuncMap{
		"getJSONSyslogFormat": func(name string) string {
			return `{"agent":"` + strings.ToLower(name) + `","level":"%LEVEL","relfile":"%ShortFilePath","line":"%Line","msg":"%Msg"%ExtraJSONContext}%n`
		},
	}
	tmpl, err := template.New("seelog_config").Funcs(funcMap).Parse(seelogConfigurationTemplate)
	if err != nil {
		return "", err
	}
	b := &bytes.Buffer{}
	err = tmpl.Execute(b, c.settings)
	return b.String(), err
}
func ( c * Config ) Render ( ) ( string , error ) { c . Lock ( ) defer c . Unlock ( ) funcMap := template . FuncMap { " " : func ( name string ) string { return `{"agent":"` + strings . ToLower ( name ) + `","level":"%LEVEL","relfile":"%ShortFilePath","line":"%Line","msg":"%Msg"%ExtraJSONContext}%n` } , } tmpl , err := template . New ( " " ) . Funcs ( funcMap ) . Parse ( seelogConfigurationTemplate ) if err != nil { return " " , err } b := & bytes . Buffer { } err = tmpl . Execute ( b , c . settings ) return b . String ( ) , err }
Render generates a string containing a valid seelog XML configuration
Render generates a string containing a valid seelog XML configuration
// This function will be called by the html/template engine that will perform HTML escaping of quotes characters in the output string