Gửi ý kiến phản hồi
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
nl:: Weave:: System:: ObjectPool
#include <src/system/SystemObject.h>
A class template used for allocating Object subclass objects from an ObjectArena<> template union.
Tóm tắt
Chi tiết
Thông số mẫu
T
một lớp con của
Object (Đối tượng) được phân bổ từ trường đấu.
N
một số nguyên dương của các đối tượng thuộc lớp T để phân bổ từ trường đấu.
Hàm tĩnh công khai
Size (void)
size_t
Returns the number of objects that can be simultaneously retained from a pool.
Hàm công khai
Get (const Layer & aLayer, size_t aIndex)
T *
Returns a pointer the object at \c aIndex or \c NULL if the object is not retained by \c aLayer.
GetStatistics (nl::Weave::System::Stats::count_t & aNumInUse, nl::Weave::System::Stats::count_t & aHighWatermark)
void
TryCreate (Layer & aLayer)
T *
Tries to initially retain the first object in the pool that is not retained by any layer.
Hàm tĩnh công khai
Kích thước
size_t Size(
void
)
Returns the number of objects that can be simultaneously retained from a pool.
Hàm công khai
Get
T * Get (
const Layer & aLayer ,
size_t aIndex
)
Returns a pointer the object at \c aIndex or \c NULL if the object is not retained by \c aLayer.
GetStatistics
void GetStatistics(
nl::Weave::System::Stats::count_t & aNumInUse,
nl::Weave::System::Stats::count_t & aHighWatermark
)
TryCreate
T * TryCreate(
Layer & aLayer
)
Tries to initially retain the first object in the pool that is not retained by any layer.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mã mẫu được cấp phép theo Giấy phép Apache 2.0 . Để biết thêm chi tiết, vui lòng tham khảo Chính sách trên trang web của Google Developers . Java là một nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết của Oracle. OPENTHREAD và các nhãn hiệu có liên quan là nhãn hiệu của Thread Group và được sử dụng theo giấy phép.
Cập nhật lần gần đây nhất: 2025-07-24 UTC.
Bạn muốn chia sẻ thêm với chúng tôi?
[[["Dễ hiểu","easyToUnderstand","thumb-up"],["Giúp tôi giải quyết được vấn đề","solvedMyProblem","thumb-up"],["Khác","otherUp","thumb-up"]],[["Thiếu thông tin tôi cần","missingTheInformationINeed","thumb-down"],["Quá phức tạp/quá nhiều bước","tooComplicatedTooManySteps","thumb-down"],["Đã lỗi thời","outOfDate","thumb-down"],["Vấn đề về bản dịch","translationIssue","thumb-down"],["Vấn đề về mẫu/mã","samplesCodeIssue","thumb-down"],["Khác","otherDown","thumb-down"]],["Cập nhật lần gần đây nhất: 2025-07-24 UTC."],[],[]]