OxL Справочник OxL
РусскийEnglish

method Response.failed

true when the call ended with a NetError (a refusal, or an error of the handler itself, that next reported).

Example:

oxl✓ проверяется в CI
fn main() io {
  print("{Response{ passed: true }.failed()} {Response.refuse(Timeout{}).failed()}")
}
Вывод
false true
pub(api) fn failed() -> bool

Сложность. O(1).

С версии. 1.0.0-beta

Возвращает

bool

Эффекты

не объявлены (чистая, пока тело не говорит иное)

Определено в: std/core/rpc.oxl:478

См. также