[Glass] _hasIndexes usage
bruno buzzi brassesco
smalltalk at adinet.com.uy
Fri Jun 5 14:04:06 PDT 2020
Dale,
Ok, then i will use your recommendation (i know _xxx is for internal
usage) but i did not search too much to find #indexSpec message.
A Java Web App display Forms with paging behavior (forms are stored in
GS) it call a REST GS Service with the page size and the page number
(the entire collection to display must be sorted by #modifiedTime inst
var).
If the collection is small asSortedCollection can be used without
problems. But if the collection is too big asSortedCollection is out of
the equation.
The collection with forms can have or not an index by #modifiedTime, if
it has an index then i want to use it with aGsQuery readStream or
aGsQuery reversedReadStream.
The at some point something like this is done:
instances _hasIndexes
ifTrue: [self fetchIndexedFormsInstancesOn: instances from:
startIndex to: endIndex] "use aGsQuery readStream"
ifFalse: [self fetchUnIndexedFormsInstancesOn: instances from:
startIndex to: endIndex] "use asSortedCollection"
regards,
bruno
More information about the Glass
mailing list