verifyUnsent method

void verifyUnsent()
inherited

Verify that this request has not yet been sent. Once it has, all fields should be considered frozen. If this request has been sent, this throws a StateError.

Implementation

void verifyUnsent() {
  if (isSent)
    throw StateError(
        'Request ($this) has already been sent and can no longer be modified.');
}