--- a/Doc/library/ossaudiodev.rst Wed Mar 18 21:36:23 2015 -0500 |
+++ b/Doc/library/ossaudiodev.rst Thu Mar 19 13:16:44 2015 +0200 |
@@ -148,21 +148,30 @@ and (read-only) attributes: |
.. method:: oss_audio_device.write(data) |
- Write the Python string *data* to the audio device and return the number of |
- bytes written. If the audio device is in blocking mode (the default), the |
- entire string is always written (again, this is different from usual Unix device |
- semantics). If the device is in non-blocking mode, some data may not be written |
+ Write a :term:`bytes-like object` *data* to the audio device and return the |
+ number of bytes written. If the audio device is in blocking mode (the |
+ default), the entire data is always written (again, this is different from |
+ usual Unix device semantics). If the device is in non-blocking mode, some |
+ data may not be written |
---see :meth:`writeall`. |
+ .. versionchanged: 3.5 |
+ Writable :term:`bytes-like object` is now accepted. |
+ |
.. method:: oss_audio_device.writeall(data) |
- Write the entire Python string *data* to the audio device: waits until the audio |
- device is able to accept data, writes as much data as it will accept, and |
- repeats until *data* has been completely written. If the device is in blocking |
- mode (the default), this has the same effect as :meth:`write`; :meth:`writeall` |
- is only useful in non-blocking mode. Has no return value, since the amount of |
- data written is always equal to the amount of data supplied. |
+ Write a :term:`bytes-like object` *data* to the audio device: waits until |
+ the audio device is able to accept data, writes as much data as it will |
+ accept, and repeats until *data* has been completely written. If the device |
+ is in blocking mode (the default), this has the same effect as |
+ :meth:`write`; :meth:`writeall` is only useful in non-blocking mode. Has |
+ no return value, since the amount of data written is always equal to the |
+ amount of data supplied. |
+ |
+ .. versionchanged: 3.5 |
+ Writable :term:`bytes-like object` is now accepted. |
+ |
.. versionchanged:: 3.2 |
Audio device objects also support the context management protocol, i.e. they can |