class UuidIndexKey implements IndexKey {
    /** */
    private final UUID key;

    /** */
    public UuidIndexKey(UUID key) {
        this.key = key;
    }

    /** {@inheritDoc} */
    @Override public Object key() {
        return key;
    }

    /** {@inheritDoc} */
    @Override public IndexKeyType type() {
        return IndexKeyType.UUID;
    }

    /** {@inheritDoc} */
    @Override public int compare(IndexKey o) {<FILL_FUNCTION_BODY>}

    /** {@inheritDoc} */
    @Override public String toString() {
        return String.valueOf(key);
    }
}

        UUID okey = (UUID)o.key();

        // Keep old logic.
        if (key.getMostSignificantBits() == okey.getMostSignificantBits())
            return Long.compare(key.getLeastSignificantBits(), okey.getLeastSignificantBits());
        else
            return key.getMostSignificantBits() > okey.getMostSignificantBits() ? 1 : -1;
    
<no_super_class>