// Enable idempotently enables containerd on a host
514564
func (r *Containerd) Enable() error {
	if err := disableOthers(r, r.Runner); err != nil {
		glog.Warningf("disableOthers: %v", err)
	}
	if err := populateCRIConfig(r.Runner, r.SocketPath()); err != nil {
		return err
	}
	if err := enableIPForwarding(r.Runner); err != nil {
		return err
	}
	// Oherwise, containerd will fail API requests with 'Unimplemented'
	return r.Runner.Run("sudo systemctl restart containerd")
}
778061
func (h *VHostHandler) Disable() {
	h.mu.Lock()
	defer h.mu.Unlock()
	h.enabled = false
}
146635
func (f *ComponentFlag) Enabled(name string) bool {
	return f.Calculated().Has(name)
}
90850
func (m *BaseMechanism) Enable(c *MechanismContext) {
	m.C = c
	atomic.CompareAndSwapInt64(&m.enabled, 0, 1)
}
385944
func (u *User) Enable() error {
	if err := u.ensureNotDeleted(); err != nil {
		return errors.Annotate(err, "cannot enable")
	}
	return errors.Annotatef(u.setDeactivated(false), "cannot enable user %q", u.Name())
}
95181
func (e *Engine) SetEnabled(enabled bool) {
	e.enableCompactionsOnOpen = enabled
	e.SetCompactionsEnabled(enabled)
}
1195755
func (client *Client) EnableCaching(config CacheConfig) error {
	cache, err := newHTTPCacheClient(client.debug, config)
	if err != nil {
		return err
	}

	client.Transport = cache
	return nil
}
297397
func (p *PWMPin) Enable(enable bool) (err error) {
	if p.enabled != enable {
		p.enabled = enable
		enableVal := 0
		if enable {
			enableVal = 1
		}
		_, err = p.write(p.pwmEnablePath(), []byte(fmt.Sprintf("%v", enableVal)))
	}
	return
}
105385
func (l *Logger) Enable(appender Appender) {
	l.appenders = append(l.appenders, appender)
}
1365473
func (s *LoadBasedAutoScalingConfiguration) SetEnable(v bool) *LoadBasedAutoScalingConfiguration {
	s.Enable = &v
	return s
}
115775
func (d *domainClient) Disable(ctx context.Context) (err error) {
	err = rpcc.Invoke(ctx, "HeadlessExperimental.disable", nil, nil, d.conn)
	if err != nil {
		err = &internal.OpError{Domain: "HeadlessExperimental", Op: "Disable", Err: err}
	}
	return
}
29454
func (m *VHostManager) Enable(name string) {
	m.mu.Lock()
	defer m.mu.Unlock()

	h, ok := m.vhosts[name]
	if !ok {
		h = NewVHostHandler()
		m.vhosts[name] = h
	}
	h.Enable()
}
18692
func (v *vaultClient) Enabled() bool {
	v.l.Lock()
	defer v.l.Unlock()
	return v.config.IsEnabled()
}
277748
func (b *BGP) Enable() error {
	_, err := b.vty.Command("enable")
	return err
}
1631
func (c *RsConnection) ContainerCDNDisable(container string) error {
	h := swift.Headers{"X-CDN-Enabled": "false"}

	_, _, err := c.manage(swift.RequestOpts{
		Container:  container,
		Operation:  "PUT",
		ErrorMap:   swift.ContainerErrorMap,
		NoResponse: true,
		Headers:    h,
	})
	return err
}
680689
func (c *CachePolicy) Enabled() bool {
	if c.EnabledFlag == "" {
		return true
	}
	enabled, _ := utils.ParseBool(c.EnabledFlag)
	return enabled
}
117119
func (q *PlanQueue) Enabled() bool {
	q.l.RLock()
	defer q.l.RUnlock()
	return q.enabled
}