def __init__(self, hass, data, name, unit_of_measurement, value_template):
        self._hass = hass
        self.data = data
        self._name = name
        self._state = False
        self._unit_of_measurement = unit_of_measurement
        self._value_template = value_template
        self.update()
Initialize the sensor.
dataset/ETHPy150Open home-assistant/home-assistant/homeassistant/components/sensor/command_line.py/CommandSensor.__init__