This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.



Preferred buffer size for ContentProvider


size = preferredBufferSize(provider)


size = preferredBufferSize(provider) returns the preferred size of data buffers of this provider. MATLAB® should use this value in the length parameter to the getData method.

Input Arguments

expand all

Content provider, specified as a object.

Output Arguments

expand all

Preferred buffer size, returned as bytes. By default this returns [], which indicates that this provider does not care what size of buffers are requested and MATLAB should choose a size. Since getData can always return fewer or more bytes than this, this value is an optimization to minimize the number of getData calls and amount of data copying that might take place.

Introduced in R2018a