CommandCompleteMessage.parse constructor
- @internal
- PgByteDataReader reader
Implementation
@internal
factory CommandCompleteMessage.parse(PgByteDataReader reader) {
final str = reader.readNullTerminatedString();
final match = _affectedRowsExp.firstMatch(str);
var rowsAffected = 0;
if (match != null) {
rowsAffected = int.parse(match.group(0)!);
}
return CommandCompleteMessage._(rowsAffected);
}