From 497bc6ac0dc90af029310300c608e4a6b38f3ad1 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 13 Jul 2016 14:47:29 +0200 Subject: [PATCH] Update docstrings (#2513) --- homeassistant/components/binary_sensor/envisalink.py | 2 +- homeassistant/components/binary_sensor/knx.py | 6 +++--- homeassistant/components/binary_sensor/nx584.py | 2 +- homeassistant/components/binary_sensor/wink.py | 4 ++-- homeassistant/components/binary_sensor/zigbee.py | 2 +- homeassistant/components/binary_sensor/zwave.py | 2 +- homeassistant/components/switch/knx.py | 4 +--- homeassistant/components/switch/verisure.py | 2 +- homeassistant/components/switch/zigbee.py | 2 +- homeassistant/components/switch/zwave.py | 4 ++-- 10 files changed, 14 insertions(+), 16 deletions(-) diff --git a/homeassistant/components/binary_sensor/envisalink.py b/homeassistant/components/binary_sensor/envisalink.py index 0d82626685a..6ed257bd809 100644 --- a/homeassistant/components/binary_sensor/envisalink.py +++ b/homeassistant/components/binary_sensor/envisalink.py @@ -19,7 +19,7 @@ _LOGGER = logging.getLogger(__name__) def setup_platform(hass, config, add_devices_callback, discovery_info=None): - """Perform the setup for Envisalink sensor devices.""" + """Setup Envisalink binary sensor devices.""" _configured_zones = discovery_info['zones'] for zone_num in _configured_zones: _device_config_data = ZONE_SCHEMA(_configured_zones[zone_num]) diff --git a/homeassistant/components/binary_sensor/knx.py b/homeassistant/components/binary_sensor/knx.py index f7730407b23..e5a36ceb867 100644 --- a/homeassistant/components/binary_sensor/knx.py +++ b/homeassistant/components/binary_sensor/knx.py @@ -2,7 +2,7 @@ Contains functionality to use a KNX group address as a binary. For more details about this platform, please refer to the documentation at -https://home-assistant.io/components/switch.knx/ +https://home-assistant.io/components/binary_sensor.knx/ """ from homeassistant.components.binary_sensor import BinarySensorDevice from homeassistant.components.knx import ( @@ -12,13 +12,13 @@ DEPENDENCIES = ["knx"] def setup_platform(hass, config, add_entities, discovery_info=None): - """Create and add an entity based on the configuration.""" + """Setup the KNX binary sensor platform.""" add_entities([ KNXSwitch(hass, KNXConfig(config)) ]) class KNXSwitch(KNXGroupAddress, BinarySensorDevice): - """Representation of a KNX sensor device.""" + """Representation of a KNX binary sensor device.""" pass diff --git a/homeassistant/components/binary_sensor/nx584.py b/homeassistant/components/binary_sensor/nx584.py index 5c4ca78b14e..6a287599e69 100644 --- a/homeassistant/components/binary_sensor/nx584.py +++ b/homeassistant/components/binary_sensor/nx584.py @@ -18,7 +18,7 @@ _LOGGER = logging.getLogger(__name__) def setup_platform(hass, config, add_devices, discovery_info=None): - """Setup nx584 sensors.""" + """Setup nx584 binary sensor platform.""" from nx584 import client as nx584_client host = config.get('host', 'localhost:5007') diff --git a/homeassistant/components/binary_sensor/wink.py b/homeassistant/components/binary_sensor/wink.py index 17f4544a5ea..90d4f0a5cd5 100644 --- a/homeassistant/components/binary_sensor/wink.py +++ b/homeassistant/components/binary_sensor/wink.py @@ -24,7 +24,7 @@ SENSOR_TYPES = { def setup_platform(hass, config, add_devices, discovery_info=None): - """Setup the Wink platform.""" + """Setup the Wink binary sensor platform.""" import pywink if discovery_info is None: @@ -44,7 +44,7 @@ def setup_platform(hass, config, add_devices, discovery_info=None): class WinkBinarySensorDevice(WinkDevice, BinarySensorDevice, Entity): - """Representation of a Wink sensor.""" + """Representation of a Wink binary sensor.""" def __init__(self, wink): """Initialize the Wink binary sensor.""" diff --git a/homeassistant/components/binary_sensor/zigbee.py b/homeassistant/components/binary_sensor/zigbee.py index ac9e542c9d5..7e4139d4680 100644 --- a/homeassistant/components/binary_sensor/zigbee.py +++ b/homeassistant/components/binary_sensor/zigbee.py @@ -12,7 +12,7 @@ DEPENDENCIES = ["zigbee"] def setup_platform(hass, config, add_entities, discovery_info=None): - """Create and add an entity based on the configuration.""" + """Setup the ZigBee binary sensor platform.""" add_entities([ ZigBeeBinarySensor(hass, ZigBeeDigitalInConfig(config)) ]) diff --git a/homeassistant/components/binary_sensor/zwave.py b/homeassistant/components/binary_sensor/zwave.py index 14268e1c124..29ee7790b45 100644 --- a/homeassistant/components/binary_sensor/zwave.py +++ b/homeassistant/components/binary_sensor/zwave.py @@ -31,7 +31,7 @@ DEVICE_MAPPINGS = { def setup_platform(hass, config, add_devices, discovery_info=None): - """Setup the Z-Wave platform for sensors.""" + """Setup the Z-Wave platform for binary sensors.""" if discovery_info is None or zwave.NETWORK is None: return diff --git a/homeassistant/components/switch/knx.py b/homeassistant/components/switch/knx.py index b2866223350..4ed24e68d4d 100644 --- a/homeassistant/components/switch/knx.py +++ b/homeassistant/components/switch/knx.py @@ -3,8 +3,6 @@ Support KNX switching actuators. For more details about this platform, please refer to the documentation at https://home-assistant.io/components/switch.knx/ - -(c) 2016 Daniel Matuschek """ from homeassistant.components.switch import SwitchDevice from homeassistant.components.knx import ( @@ -14,7 +12,7 @@ DEPENDENCIES = ["knx"] def setup_platform(hass, config, add_entities, discovery_info=None): - """Create and add an entity based on the configuration.""" + """Setup the KNX switch platform.""" add_entities([ KNXSwitch(hass, KNXConfig(config)) ]) diff --git a/homeassistant/components/switch/verisure.py b/homeassistant/components/switch/verisure.py index f2943058452..1bd0a46fb78 100644 --- a/homeassistant/components/switch/verisure.py +++ b/homeassistant/components/switch/verisure.py @@ -13,7 +13,7 @@ _LOGGER = logging.getLogger(__name__) def setup_platform(hass, config, add_devices, discovery_info=None): - """Setup the Verisure platform.""" + """Setup the Verisure switch platform.""" if not int(hub.config.get('smartplugs', '1')): return False diff --git a/homeassistant/components/switch/zigbee.py b/homeassistant/components/switch/zigbee.py index 1c88b4f78a8..4588be139a2 100644 --- a/homeassistant/components/switch/zigbee.py +++ b/homeassistant/components/switch/zigbee.py @@ -12,7 +12,7 @@ DEPENDENCIES = ["zigbee"] def setup_platform(hass, config, add_entities, discovery_info=None): - """Create and add an entity based on the configuration.""" + """Setup the ZigBee switch platform.""" add_entities([ ZigBeeSwitch(hass, ZigBeeDigitalOutConfig(config)) ]) diff --git a/homeassistant/components/switch/zwave.py b/homeassistant/components/switch/zwave.py index f59d830f4c0..c1ad3d36f2d 100644 --- a/homeassistant/components/switch/zwave.py +++ b/homeassistant/components/switch/zwave.py @@ -1,5 +1,5 @@ """ -Zwave platform that handles simple binary switches. +Z-Wave platform that handles simple binary switches. For more details about this platform, please refer to the documentation at https://home-assistant.io/components/switch.zwave/ @@ -12,7 +12,7 @@ from homeassistant.components import zwave # pylint: disable=unused-argument def setup_platform(hass, config, add_devices, discovery_info=None): - """Find and return Z-Wave switches.""" + """Setup the Z-Wave platform.""" if discovery_info is None or zwave.NETWORK is None: return