// Init allows user to override the defaults (a set of OS signals to watch for, for example).
513748
func Init(cfg Config) {
	c.sem.Lock()
	signal.Stop(c.signalChan)
	close(c.cancelWaitChan)
	c.codeOK = cfg.ExitCodeOK
	c.codeErr = cfg.ExitCodeErr
	c.signals = cfg.ExitSignals
	signal.Notify(c.signalChan, c.signals...)
	go c.wait()
	c.sem.Unlock()
}
218557
func (b *sqsBroker) Init(opts ...broker.Option) error {
	for _, o := range opts {
		o(&b.options)
	}

	return nil
}
756109
func (f *FlagSet) Init(name string, errorHandling ErrorHandling) {
	f.name = name
	f.envPrefix = EnvironmentPrefix
	f.errorHandling = errorHandling
}
425447
func (h *Handler) init(cfg config.Configuration) error {
	if cfg.Sampler != nil && cfg.Sampler.SamplingServerURL == "" {
		cfg.Sampler.SamplingServerURL = h.samplingServerURL
	}
	if cfg.Reporter != nil && cfg.Reporter.LocalAgentHostPort == "" {
		cfg.Reporter.LocalAgentHostPort = h.agentHostPort
	}
	tracer, _, err := cfg.New(common.DefaultTracerServiceName)
	if err != nil {
		return err
	}
	h.tracers[cfg.Sampler.Type] = tracer
	return nil
}
1207438
func Init(prefix string, flag int) {
	logger = log.New(os.Stdout, prefix, flag)
}
950775
func (c *Config) Init() {
	if c.Tags == nil {
		c.Tags = make(map[string]string)
	}
}
337417
func Init(config Config) {
	err := Global.Apply(config)
	if err != nil {
		panic(err)
	}
}
706290
func (c *defaultsCommand) Init(args []string) error {
	// There's no way of distinguishing a cloud name
	// from a model configuration setting without contacting the
	// API, but we aren't allowed to contact the API at Init time,
	// so we defer parsing the arguments until Run is called.
	c.args = args
	return nil
}
1308010
func (is *InfoSyncer) Init(ctx context.Context) error {
	return is.newSessionAndStoreServerInfo(ctx, owner.NewSessionDefaultRetryCnt)
}
270688
func init() {
	zeroArg = make([]reflect.Value, 0)
	zeroArgInterf = make([]interface{}, 0)
	trueInterf = true
	falseInterf = false
	nilInterf = nil
}
351796
func Init(preferences *prefs.Preferences) {
	enableColours := preferences.Core.EnableColors

	if !Attached() {
		enableColours = false
	}

	defUI = &UI{
		Indent: 0,
		Cols:   screenWidth(),

		EnableProgress: preferences.Core.EnableProgress,
		EnableHints:    preferences.Core.EnableHints,
		EnableColors:   enableColours,
	}
}
793262
func (m *Manifest) Init() {
	if m.Roots == nil {
		defaultRoots := []string{""}
		m.Roots = &defaultRoots
	}
}
1328854
func (a *Application) init(confFile string) {
	a.InitEBus()
	a.initRouter()
	a.initConf(confFile)

	// neo logger
	lvl, err := parseLogLevel(a.Conf.Neo.Logger.Level)
	if err != nil {
		log.Warn(err)
	} else {
		log.Level = lvl
	}

	// application logger
	lvl, err = parseLogLevel(a.Conf.App.Logger.Level)
	a.Logger = golog.GetLogger(a.Conf.App.Logger.Name)
	if err != nil {
		log.Warn(err)
	} else {
		a.Logger.Level = lvl
	}
}
1276943
func (l *Listener) init() {
	l.Lock()
	defer l.Unlock()
	if l.closing == nil {
		l.closing = make(chan struct{})
	}

	// Initialize l.connc only if the listener is not yet closed.
	select {
	case <-l.closing:
	default:
		if l.connc == nil {
			l.connc = make(chan *Conn)
		}
	}
}
151195
func init() {
	for _, v := range os.Args {
		if v == "--version" || v == "-version" {
			fmt.Println(VersionString())
			os.Exit(0)
		}
	}
}
412802
func (r *Rx) Init(tx, rx []byte, sharedEventFDState *uint32) {
	r.sharedEventFDState = sharedEventFDState
	r.tx.Init(tx)
	r.rx.Init(rx)
}
486319
func (c *config) Init() error {
	err := c.handler.Init()
	c.log(INIT, err)
	return err
}