# Path: src/alexapi/triggers/basetrigger.py
# class BaseTrigger:
# 	__metaclass__ = ABCMeta
# 
# 	name = ''
# 	type = None
# 	event_type = None
# 	voice_confirm = None
# 
# 	_trigger_callback = None
# 	_config = None
# 	_tconfig = None
# 
# 	def __init__(self, config, trigger_callback):
# 
# 		self._config = config
# 		self._tconfig = config['triggers'][self.name]
# 		self._trigger_callback = trigger_callback
# 		self.voice_confirm = self._tconfig['voice_confirm']
# 
# 		self.validate_config()
# 
# 	def validate_config(self):
# 		pass
# 
# 	@abstractmethod
# 	def setup(self):
# 		pass
# 
# 	@abstractmethod
# 	def run(self):
# 		pass
# 
# 	@abstractmethod
# 	def enable(self):
# 		pass
# 
# 	@abstractmethod
# 	def disable(self):
# 		pass
# 
# 	def cleanup(self):
# 		pass


import time
import os
import threading
import logging
import alexapi.triggers as triggers
from .basetrigger import BaseTrigger


logger = logging.getLogger(__name__)


class PlatformTrigger(BaseTrigger):

	type = triggers.TYPES.OTHER
	name = 'platform'

	_platform_continuous_callback = None

	def __init__(self, config, trigger_callback):

		super(PlatformTrigger, self).__init__(config, trigger_callback)

		event_types = {
			'oneshot-vad': triggers.EVENT_TYPES.ONESHOT_VAD,
			'continuous': triggers.EVENT_TYPES.CONTINUOUS,

# Path: src/alexapi/triggers/basetrigger.py
# class BaseTrigger:
# 	__metaclass__ = ABCMeta
# 
# 	name = ''
# 	type = None
# 	event_type = None
# 	voice_confirm = None
# 
# 	_trigger_callback = None
# 	_config = None
# 	_tconfig = None
# 
# 	def __init__(self, config, trigger_callback):
# 
# 		self._config = config
# 		self._tconfig = config['triggers'][self.name]
# 		self._trigger_callback = trigger_callback
# 		self.voice_confirm = self._tconfig['voice_confirm']
# 
# 		self.validate_config()
# 
# 	def validate_config(self):
# 		pass
# 
# 	@abstractmethod
# 	def setup(self):
# 		pass
# 
# 	@abstractmethod
# 	def run(self):
# 		pass
# 
# 	@abstractmethod
# 	def enable(self):
# 		pass
# 
# 	@abstractmethod
# 	def disable(self):
# 		pass
# 
# 	def cleanup(self):
# 		pass


# Path: src/alexapi/triggers/platformtrigger.py
import time
import os
import threading
import logging
import alexapi.triggers as triggers
from .basetrigger import BaseTrigger



logger = logging.getLogger(__name__)


class PlatformTrigger(BaseTrigger):

	type = triggers.TYPES.OTHER
	name = 'platform'

	_platform_continuous_callback = None

	def __init__(self, config, trigger_callback):

		super(PlatformTrigger, self).__init__(config, trigger_callback)

		event_types = {
			'oneshot-vad': triggers.EVENT_TYPES.ONESHOT_VAD,
			'continuous': triggers.EVENT_TYPES.CONTINUOUS,

			'continuous-vad': triggers.EVENT_TYPES.CONTINUOUS_VAD