code: func ParseLogClass(s string) (LogClass, error) {
  	switch strings.ToLower(s) {
  	case "none":
  		return NONE, nil
  	case "trace":
  		return TRACE, nil
  	case "trace+":
  		return TRACEPLUS, nil
  	case "debug":
  		return DEBUG, nil
  	case "debug+":
  		return DEBUGPLUS, nil
  	case "info":
  		return INFO, nil
  	case "info+":
  		return INFOPLUS, nil
  	case "warn":
  		return WARN, nil
  	case "warn+":
  		return WARNPLUS, nil
  	case "error":
  		return ERROR, nil
  	case "error+":
  		return ERRORPLUS, nil
  	case "fatal":
  		return FATAL, nil
  	case "fatal+":
  		return FATALPLUS, nil
  	case "all":
  		return ALL, nil
  	}
  	return NONE, fmt.Errorf("Invalid LogClass string.")
  }
docs: // Parses a logclass string into a LogClass object. This call is case
  // insensitive. If the string is not recognised then an error will be returned
  // and LogClass will be set to NONE.