// New returns an initialized Viper instance.
541160
func New() *Viper {
	v := new(Viper)
	v.keyDelim = "."
	v.configName = "config"
	v.configPermissions = os.FileMode(0644)
	v.fs = afero.NewOsFs()
	v.config = make(map[string]interface{})
	v.override = make(map[string]interface{})
	v.defaults = make(map[string]interface{})
	v.kvstore = make(map[string]interface{})
	v.pflags = make(map[string]FlagValue)
	v.env = make(map[string]string)
	v.aliases = make(map[string]string)
	v.typeByDefValue = false

	return v
}
1175107
func (l *Logger) New(ctx *gear.Context) (interface{}, error) {
	log := Log{}
	l.init(log, ctx)
	return log, nil
}
1015904
func New(r *hal.Robot) (hal.Adapter, error) {
	a := &adapter{
		out:  bufio.NewWriter(os.Stdout),
		in:   bufio.NewReader(os.Stdin),
		quit: make(chan bool),
	}
	a.SetRobot(r)
	return a, nil
}
847651
func New() (*Ipvs, error) {
	handler, err := ipvs.New("")
	if err != nil {
		return nil, fmt.Errorf("[ipvs] Initialisation failed: %v", err)
	}

	if err := handler.Flush(); err != nil {
		return nil, fmt.Errorf("[ipvs] Flushing table failed: %v", err)
	}

	return &Ipvs{
		handler: handler,
	}, nil
}
955906
func New(robot *hal.Robot) (hal.Store, error) {
	s := &store{
		data: map[string][]byte{},
	}
	s.SetRobot(robot)
	return s, nil
}
96590
func New(cluster cluster.Cluster, config types.Config, rpcch chan struct{}) *Vibranium {
	return &Vibranium{cluster: cluster, config: config, counter: sync.WaitGroup{}, rpcch: rpcch}
}
810182
func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakListOptions internalinterfaces.TweakListOptionsFunc) Interface {
	return &version{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
}
420575
func New(beCfg engine.Backend, opts proxy.Options, beSrvs []Srv) (*T, error) {
	tpCfg, err := newTransportCfg(beCfg.HTTPSettings(), opts)
	if err != nil {
		return nil, errors.Wrap(err, "bad config")
	}
	return &T{
		id:      beCfg.Id,
		httpCfg: beCfg.HTTPSettings(),
		httpTp:  newTransport(tpCfg),
		srvs:    beSrvs,
	}, nil
}
356550
func (cloudstack CloudstackClient) New(apiurl string, apikey string, secretkey string, insecureskipverify bool) *CloudstackClient {
	c := &CloudstackClient{
		client: &http.Client{
			Transport: &http.Transport{
				TLSClientConfig: &tls.Config{InsecureSkipVerify: insecureskipverify},
				Proxy:           http.ProxyFromEnvironment,
			},
		},
		BaseURL:   apiurl,
		APIKey:    apikey,
		SecretKey: secretkey,
	}
	return c
}
48629
func New(sigtermTimeout time.Duration, env []string, command string, args ...string) (*Instance, chan error, error) {
	s := &Instance{
		command:        command,
		args:           args,
		env:            env,
		commandExit:    make(chan error, 1),
		sigtermTimeout: sigtermTimeout,
		signalChan:     make(chan os.Signal, 1),
	}
	go s.loop()
	return s, s.commandExit, nil
}
1119944
func New() *Martini {
	m := &Martini{Injector: inject.New(), action: func() {}, logger: log.New(os.Stdout, "[martini] ", 0)}
	m.Map(m.logger)
	m.Map(defaultReturnHandler())
	return m
}
1318683
func New(addr string) (Client, error) {
	factory, ok := factories[*protocol]
	if !ok {
		return nil, fmt.Errorf("unknown throttler client protocol: %v", *protocol)
	}
	return factory(addr)
}
475486
func New(exec utilexec.Interface) Interface {
	handle, err := libipvs.New("")
	if err != nil {
		klog.Errorf("IPVS interface can't be initialized, error: %v", err)
		return nil
	}
	return &runner{
		exec:       exec,
		ipvsHandle: handle,
	}
}
83505
func (factory *TelegramBeeFactory) New(name, description string, options bees.BeeOptions) bees.BeeInterface {
	bee := TelegramBee{
		Bee: bees.NewBee(name, factory.ID(), description, options),
	}
	bee.ReloadOptions(options)

	return &bee
}
1017410
func (factory *GitHubBeeFactory) New(name, description string, options bees.BeeOptions) bees.BeeInterface {
	bee := GitHubBee{
		Bee: bees.NewBee(name, factory.ID(), description, options),
	}
	bee.ReloadOptions(options)

	return &bee
}
678042
func New(ml, mf, mt int, level Level) *Safety {
	return &Safety{ml, mf, mt, level}
}
563158
func New(c Config) (Monitor, error) {
	m := &monitor{
		tip:            []string{""},
		path:           c.Path,
		scanner:        c.Scanner,
		sorter:         c.Sorter,
	}

	if err := m.sync(); err != nil {
		return nil, err
	}

	return m, nil
}