Humdinger wrote on Fri, 16 Nov 2007 18:03:16 +0100: > When you define the attribute you have several options for "Type". Besides > String, there > is Boolean, Float, Double etc. There are also different Integers, 8/16/32/64 > bit. > I was wondering, if the mkindex command doesn't have to be extended with > these different > sizes. Currently there's only one "int". There's also the long 64 bit integer in BeOS, as well as the 32 bit one. No smaller ones. BeOS's BFS/mkindex supported int (32 bit), llong (64 bit), string, float or double. Time may have been done as a 64 bit int. I suspect signed and unsigned integer attributes were treated equally by BFS, using the same compare code (does that work mathematically?). Floats came in useful for me for the Spam rating of e-mail, a fraction from 0.0 to 1.0. Strings are obviously useful everywhere, though OpenTracker had trouble sorting empty strings (would ignore the secondary sort column when it shouldn't have). And for indexing, only the first 256? bytes of a string attribute were indexed and compared against. So for file types, anything you can stuff into bytes can be used. But only ones that the file system knows about (has a comparison function internally) can be indexed. Though if the index value comparison code were extracted out of the file system, it could be more generic and we could add new indexable types to older file systems. Same for code for displaying a readable version of new data types - would help with OpenTracker and other attribute displayers. Which perhaps leads to adding data types to the Translator system... - Alex