Add documentation for the remote.delete_command service (#763)

This commit is contained in:
Felipe Martins Diel 2021-01-06 16:19:03 -03:00 committed by GitHub
parent 9913c46891
commit c72638907f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -16,7 +16,8 @@ Properties should always only return information from memory and not do I/O (lik
| Constant | Description
| -------- | -----------
| `SUPPORT_LEARN_COMMAND` | Entity allows learning commands from devices.
| `SUPPORT_LEARN_COMMAND` | Entity allows learning commands from devices.
| `SUPPORT_DELETE_COMMAND` | Entity allows deleting commands from devices.
## Methods
@ -45,3 +46,17 @@ class MyRemote(RemoteEntity):
async def async_learn_command(self, **kwargs):
"""Learn a command from a device."""
```
### Delete Command
Only implement this method if the flag `SUPPORT_DELETE_COMMAND` is set.
```python
class MyRemote(RemoteEntity):
def delete_command(self, **kwargs):
"""Delete a command from a device."""
async def async_delete_command(self, **kwargs):
"""Delete a command from a device."""
```