IVariantComparer Interface
Use this Interface to define how a container of variant can be sorted. Containers like VariantArray and VariantCollection can be sorted when they get a reference to a class that implements IVariantComparer.
Note:Interfaces don't actually do anything. A Interface is just a promise of what methods a implementor of a interface will have.
interface IVariantComparer
Methods
Compare | Implement this method to have a valid class that implements the IVariantComparer Interface.
The implemented method should return:
-1 if variant a < variant b
1 if variant a > variant b
0 if variant a = variant b
So what needs to be done is
if(variant a < variant b) then
return -1
elseif(variant a > variant b) then
return 1
else
return 0
end if |
[Footnote]
Supported Platforms:
MacOS X CarbonMacOS X Cocoa 32 bitMacOS X Cocoa 64 bitWindows 32 bitWindows 64 bitLinux 32 bitLinux 64 bitLinux ARM