Main Content



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.

Version History

Introduced in R2018a