# write method | |
int write | |
(ByteData data, [List<[Handle](../../zircon/Handle-class.md)> handles]) | |
## Implementation | |
```dart | |
int write(ByteData data, [List<Handle>? handles]) { | |
if (handle == null) { | |
return ZX.ERR_INVALID_ARGS; | |
} | |
return System.channelWrite(handle!, data, handles ?? []); | |
} | |
``` | |