Skip to content

Commit

Permalink
[BOT] Updating 0835355 content
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Jun 30, 2024
1 parent 0835355 commit 91f3522
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 18 deletions.
15 changes: 7 additions & 8 deletions book/ch15-05-interior-mutability.html
Original file line number Diff line number Diff line change
Expand Up @@ -245,14 +245,13 @@ <h4 id="ichki-ozgaruvchanlik-uchun-foydalanish-holatimisoli-soxta-obyektlar"><a
aktyorning o'rniga chiqib, sahna ko'rinishi amalga oshirib beruvchi, ya'nikino yaratishda &quot;kaskadyor&quot;
misolida ko'rib chiqaylik. Test doublelari boshqa turlarda test o'tkazayotganimizda xizmat qiladi.
<em>Soxta obyektlar</em> test paytida nimalar sodir bo'lishini qayd etuvchi test doublelar o'ziga xos turlardan biri bo'lib, siz to'g'ri amallar amalga oshirilayotganini ko'zdan kechirishingiz mumkin.</p>
<p>Rust doesn’t have objects in the same sense as other languages have objects,
and Rust doesn’t have mock object functionality built into the standard library
as some other languages do. However, you can definitely create a struct that
will serve the same purposes as a mock object.</p>
<p>Here’s the scenario we’ll test: we’ll create a library that tracks a value
against a maximum value and sends messages based on how close to the maximum
value the current value is. This library could be used to keep track of a
user’s quota for the number of API calls they’re allowed to make, for example.</p>
<p>Rustda boshqa dasturlash tillari kabi bir xil ma'noli obyektlarga ega emas,
va soxta obyekt funksionalligini olgan standart kutubxonasi yo'q. Aksincha, soxta
obyektlar kabi ish bajaruvchi struct yaratishingiz mumkin. </p>
<p>Ushbu ssenariyni ko'rib chiqaylik: qiymatni maksimal qiymatga nisbatan kuzatuvchi
kutubxona yaratamiz va joriy qiymat maksimal qiymatga qanchalik yaqinligiga qarab bizga
xabar jo'natib turadi. Ushbu kutubxona foydalanuvchi uchun ruxsat etilgan API 'call'lar sonini
kuzatib borish uchun ishlatilishi mumkin, bu ishlatish mumkin bo'lgan bir misol.</p>
<p>Our library will only provide the functionality of tracking how close to the
maximum a value is and what the messages should be at what times. Applications
that use our library will be expected to provide the mechanism for sending the
Expand Down
15 changes: 7 additions & 8 deletions book/print.html
Original file line number Diff line number Diff line change
Expand Up @@ -13041,14 +13041,13 @@ <h4 id="ichki-ozgaruvchanlik-uchun-foydalanish-holatimisoli-soxta-obyektlar"><a
aktyorning o'rniga chiqib, sahna ko'rinishi amalga oshirib beruvchi, ya'nikino yaratishda &quot;kaskadyor&quot;
misolida ko'rib chiqaylik. Test doublelari boshqa turlarda test o'tkazayotganimizda xizmat qiladi.
<em>Soxta obyektlar</em> test paytida nimalar sodir bo'lishini qayd etuvchi test doublelar o'ziga xos turlardan biri bo'lib, siz to'g'ri amallar amalga oshirilayotganini ko'zdan kechirishingiz mumkin.</p>
<p>Rust doesn’t have objects in the same sense as other languages have objects,
and Rust doesn’t have mock object functionality built into the standard library
as some other languages do. However, you can definitely create a struct that
will serve the same purposes as a mock object.</p>
<p>Here’s the scenario we’ll test: we’ll create a library that tracks a value
against a maximum value and sends messages based on how close to the maximum
value the current value is. This library could be used to keep track of a
user’s quota for the number of API calls they’re allowed to make, for example.</p>
<p>Rustda boshqa dasturlash tillari kabi bir xil ma'noli obyektlarga ega emas,
va soxta obyekt funksionalligini olgan standart kutubxonasi yo'q. Aksincha, soxta
obyektlar kabi ish bajaruvchi struct yaratishingiz mumkin. </p>
<p>Ushbu ssenariyni ko'rib chiqaylik: qiymatni maksimal qiymatga nisbatan kuzatuvchi
kutubxona yaratamiz va joriy qiymat maksimal qiymatga qanchalik yaqinligiga qarab bizga
xabar jo'natib turadi. Ushbu kutubxona foydalanuvchi uchun ruxsat etilgan API 'call'lar sonini
kuzatib borish uchun ishlatilishi mumkin, bu ishlatish mumkin bo'lgan bir misol.</p>
<p>Our library will only provide the functionality of tracking how close to the
maximum a value is and what the messages should be at what times. Applications
that use our library will be expected to provide the mechanism for sending the
Expand Down
2 changes: 1 addition & 1 deletion book/searchindex.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion book/searchindex.json

Large diffs are not rendered by default.

0 comments on commit 91f3522

Please sign in to comment.