// Enable implements Mechanism interface.
190155
func (m *OFPMechanism) Enable(c *mech.MechanismContext) {
	m.BaseMechanism.Enable(c)

	m.C.Mux.HandleFunc(of.T_ECHO_REQUEST, m.echoHandler)

	log.InfoLog("ofp/ENABLE_HOOK",
		"Mechanism ofp1.3 enabled")
}
555906
func (module *BBAnalogModule) Enable() error {
	// once-off initialisation of analog
	if !module.analogInitialised {
		path, e := findFirstMatchingFile("/sys/devices/bone_capemgr.*/slots")
		if e != nil {
			return e
		}

		// determine if cape-bone-iio is already in the file. If so, we've already initialised it.
		if !module.hasCapeBoneIIO(path) {
			// enable analog
			e = WriteStringToFile(path, "cape-bone-iio")
			if e != nil {
				return e
			}
		}

		// determine path where analog files are
		path, e = findFirstMatchingFile("/sys/devices/ocp.*/helper.*/AIN0")
		if e != nil {
			return e
		}
		if path == "" {
			return errors.New("Could not locate /sys/devices/ocp.*/helper.*/AIN0")
		}

		// remove AIN0 to get the path where these files are
		module.analogValueFilesPath = strings.TrimSuffix(path, "AIN0")

		module.analogInitialised = true

		// attempt to assign all pins to this module
		for pin, _ := range module.definedPins {
			// attempt to assign this pin for this module.
			e = AssignPin(pin, module)
			if e != nil {
				return e
			}
		}
	}
	return nil
}
1060441
func (s *RequestProgress) SetEnabled(v bool) *RequestProgress {
	s.Enabled = &v
	return s
}
888708
func (pm *Manager) Enable(name string, config *types.PluginEnableConfig) error {
	return errNotSupported
}
853765
func (pm *Manager) Disable(name string, config *types.PluginDisableConfig) error {
	return errNotSupported
}
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
}
778061
func (h *VHostHandler) Disable() {
	h.mu.Lock()
	defer h.mu.Unlock()
	h.enabled = false
}
674930
func (s *DeviceDescription) SetEnabled(v bool) *DeviceDescription {
	s.Enabled = &v
	return s
}
524356
func (s *CrlConfiguration) SetEnabled(v bool) *CrlConfiguration {
	s.Enabled = &v
	return s
}
1309999
func (this *Server) Enabled(n string) bool {
	return this.Get(n) == TRUE
}
345723
func (s *Configuration) SetEnabled(v bool) *Configuration {
	s.Enabled = &v
	return s
}
666822
func (ep *endpoint) enableService() {
	ep.Lock()
	defer ep.Unlock()
	ep.serviceEnabled = true
}
9348
func (c *UIConfig) Enabled() bool {
	c.l.RLock()
	defer c.l.RUnlock()
	return c.enabled
}
1351866
func (c *Compactor) EnableCompactions() {
	c.mu.Lock()
	c.compactionsEnabled = true
	if c.compactionsInterrupt == nil {
		c.compactionsInterrupt = make(chan struct{})
	}
	c.mu.Unlock()
}
699098
func (o *ResourceConfig) EnableAll() {
	for k := range o.GroupVersionConfigs {
		o.GroupVersionConfigs[k] = true
	}
}
1277953
func Enable(id ID, when When, what Action) error {
	if v, ok := chaos[id]; !ok {
		return ErrNoEnt
	} else {
		v.Enabled = true
		v.When = when
		v.What = what
	}
	return nil
}
619520
func (s *GetAccountSendingEnabledOutput) SetEnabled(v bool) *GetAccountSendingEnabledOutput {
	s.Enabled = &v
	return s
}