Skip to content

Commit

Permalink
Update ViewAllocator and DrawableAllocator doc
Browse files Browse the repository at this point in the history
Summary: As per title. Adding an info about disabling pooling by setting `poolSize` to 0.

Reviewed By: adityasharat

Differential Revision: D47791254

fbshipit-source-id: b3256cf43f38a0ce242d6dd2220dfd8ca8904fb4
  • Loading branch information
zielinskimz authored and facebook-github-bot committed Jul 26, 2023
1 parent eaf5a3f commit 99fe270
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import com.facebook.rendercore.RenderUnit
* A [ContentAllocator] that allocates an instance of a [View].
*
* @property poolSize The size of the content pool. The default is [DEFAULT_MAX_PREALLOCATION].
* Setting this to 0 disables pooling of the content [View].
* @property canPreallocate The flag indicating if the content pool for this Primitive should be
* filled ahead of time. See [ContentAllocator.canPreallocate]. The default is false.
* @property allocator The lambda callback that returns the actual [View].
Expand All @@ -51,6 +52,7 @@ class ViewAllocator<Content : View>(
* A [ContentAllocator] that allocates an instance of a [Drawable].
*
* @property poolSize The size of the content pool. The default is [DEFAULT_MAX_PREALLOCATION].
* Setting this to 0 disables pooling of the content [Drawable].
* @property canPreallocate The flag indicating if the content pool for this Primitive should be
* filled ahead of time. See [ContentAllocator.canPreallocate]. The default is false.
* @property allocator The lambda callback that returns the actual [Drawable].
Expand Down

0 comments on commit 99fe270

Please sign in to comment.