PropertyHandle :: ChangeBuffer - Change collection buffer count
Instances for a PropertyHandle can be read in block mode. The function allocates a buffer size to the property handle, i.e. the number of instances that will be read at once. When a buffer has already been allocated one may use the function to change the buffer size. Passing 0 or 1 will change from buffered read to none buffered access (same as ReleaseBuffer ()).
Buffered access can be used for reading collections with fixed type, only. Trying to enable buffered access for untyped or weak typed collections will fail without writing an error to the error log file.
When passing AUTO as buffer size the number of instances stored in the collection is reserved. Thus, the complete collection is read into the buffer.
When a filter has been defined for the property handle only instances are read into the buffer that fulfill the filter condition.
Usually the buffer is filled automatically when reading an instance that is not contained in the buffer. The system tries to read as many instances as defined in buffer size from the current position. Subsequent Get() request will read from the buffer as long as possible. Cancel() will cancel the current selection but not the instances in the buffer.
To position the buffer on a certain instance one may use the ReadBuffer() function. For resetting the buffer one may use the CancelBuffer () function.
One cannot use block mode for views containing references. In this case the function will ignore the request and buffer size remains 1. There are also problems in client/server mode when referring to sub property handles for references in instances that have been reading in block mode. Moreover, block mode cannot be used for updating instances.
Implementation details
- buffnum
- Number of instance buffers to be used
Default: AUTO