Package org.redisson
Class RedissonBitSet
java.lang.Object
org.redisson.RedissonObject
org.redisson.RedissonBitSet
- All Implemented Interfaces:
RBitSet,RBitSetAsync,RExpirable,RExpirableAsync,RObject,RObjectAsync
- Author:
- Nikita Koksharov
-
Field Summary
Fields inherited from class org.redisson.RedissonObject
codec, commandExecutor, name -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidExecutes AND operation over this object and specified bitsets.Executes AND operation over this object and specified bitsets.asBitSet()longReturns the number of bits set to one.Returns the number of bits set to one.voidclear()Set all bits to zerobooleanclear(long bitIndex) Set bit to zero at specifiedbitIndexvoidclear(long fromIndex, long toIndex) Set all bits to zero fromfromIndex(inclusive) totoIndex(exclusive)Set all bits to zeroclearAsync(long bitIndex) Set bit to zero at specifiedbitIndexclearAsync(long fromIndex, long toIndex) Set all bits to zero fromfromIndex(inclusive) totoIndex(exclusive)booleanClear an expire timeout or expire date for object.Clear an expire timeout or expire date for object in async mode.clearExpireAsync(String... keys) booleanUseRExpirable.expire(Duration)insteadbooleanSets a timeout for this object.booleanSets an expiration date for this object.expireAsync(long timeToLive, TimeUnit timeUnit) UseRExpirableAsync.expireAsync(Duration)insteadexpireAsync(long timeToLive, TimeUnit timeUnit, String param, String... keys) expireAsync(Duration duration) Set a timeout for object.expireAsync(Instant instant) Set an expire date for object.booleanexpireAt(long timestamp) UseRExpirable.expire(Instant)insteadbooleanUseRExpirable.expire(Instant)insteadexpireAtAsync(long timestamp) UseRExpirableAsync.expireAsync(Instant)insteadexpireAtAsync(long timestamp, String param, String... keys) expireAtAsync(Date timestamp) UseRExpirableAsync.expireAsync(Instant)insteadbooleanexpireIfGreater(Duration duration) Sets a timeout for this object only if it's greater than timeout set before.booleanexpireIfGreater(Instant time) Sets an expiration date for this object only if it's greater than expiration date set before.expireIfGreaterAsync(Duration duration) Sets a timeout for this object only if it's greater than timeout set before.expireIfGreaterAsync(Instant time) Sets an expiration date for this object only if it's greater than expiration date set before.booleanexpireIfLess(Duration duration) Sets a timeout for this object only if it's less than timeout set before.booleanexpireIfLess(Instant time) Sets an expiration date for this object only if it's less than expiration date set before.expireIfLessAsync(Duration duration) Sets a timeout for this object only if it's less than timeout set before.expireIfLessAsync(Instant time) Sets an expiration date for this object only if it's less than expiration date set before.booleanexpireIfNotSet(Duration duration) Sets a timeout for this object only if it hasn't been set before.booleanexpireIfNotSet(Instant time) Sets an expiration date for this object only if it hasn't been set before.expireIfNotSetAsync(Duration duration) Sets a timeout for this object only if it hasn't been set before.expireIfNotSetAsync(Instant time) Sets an expiration date for this object only if it hasn't been set before.booleanexpireIfSet(Duration duration) Sets a timeout for this object only if it has been already set.booleanexpireIfSet(Instant time) Sets an expiration date for this object only if it has been already set.expireIfSetAsync(Duration duration) Sets a timeout for this object only if it has been already set.expireIfSetAsync(Instant time) Sets an expiration date for this object only if it has been already set.booleanget(long bitIndex) Returnstrueif bit set to one andfalseoverwise.getAsync(long bitIndex) Returnstrueif bit set to one andfalseoverwise.bytegetByte(long offset) Returns byte number at specifiedoffsetgetByteAsync(long offset) Returns byte number at specifiedoffsetlongReturns expiration time of the object as the absolute Unix expiration timestamp in milliseconds.Returns expiration time of the object as the absolute Unix expiration timestamp in milliseconds.intgetInteger(long offset) Returns integer number at specifiedoffsetgetIntegerAsync(long offset) Returns integer number at specifiedoffsetlonggetLong(long offset) Returns long number at specifiedoffsetgetLongAsync(long offset) Returns long number at specifiedoffsetshortgetShort(long offset) Returns short number at specifiedoffsetgetShortAsync(long offset) Returns short number at specifiedoffsetlonggetSigned(int size, long offset) Returns signed number at specifiedoffsetandsizegetSignedAsync(int size, long offset) Returns signed number at specifiedoffsetandsizelonggetUnsigned(int size, long offset) Returns unsigned number at specifiedoffsetandsizegetUnsignedAsync(int size, long offset) Returns unsigned number at specifiedoffsetandsizebyteincrementAndGetByte(long offset, byte increment) Increments current byte value on definedincrementvalue at specifiedoffsetand returns result.incrementAndGetByteAsync(long offset, byte increment) Increments current byte value on definedincrementvalue at specifiedoffsetand returns result.intincrementAndGetInteger(long offset, int increment) Increments current integer value on definedincrementvalue at specifiedoffsetand returns result.incrementAndGetIntegerAsync(long offset, int increment) Increments current integer value on definedincrementvalue at specifiedoffsetand returns result.longincrementAndGetLong(long offset, long increment) Increments current long value on definedincrementvalue at specifiedoffsetand returns result.incrementAndGetLongAsync(long offset, long increment) Increments current long value on definedincrementvalue at specifiedoffsetand returns result.shortincrementAndGetShort(long offset, short increment) Increments current short value on definedincrementvalue at specifiedoffsetand returns result.incrementAndGetShortAsync(long offset, short increment) Increments current short value on definedincrementvalue at specifiedoffsetand returns result.longincrementAndGetSigned(int size, long offset, long increment) Increments current signed value by definedincrementvalue andsizeat specifiedoffsetand returns result.incrementAndGetSignedAsync(int size, long offset, long increment) Increments current signed value by definedincrementvalue andsizeat specifiedoffsetand returns result.longincrementAndGetUnsigned(int size, long offset, long increment) Increments current unsigned value by definedincrementvalue andsizeat specifiedoffsetand returns result.incrementAndGetUnsignedAsync(int size, long offset, long increment) Increments current unsigned value by definedincrementvalue andsizeat specifiedoffsetand returns result.longlength()Returns "logical size" = index of highest set bit plus one.Returns "logical size" = index of highest set bit plus one.voidnot()Executes NOT operation over all bitsnotAsync()Executes NOT operation over all bitsvoidExecutes OR operation over this object and specified bitsets.Executes OR operation over this object and specified bitsets.longReturns remaining time of the object in milliseconds.Returns remaining time of the object in milliseconds.booleanset(long bitIndex) Set bit to one at specified bitIndexvoidset(long[] indexArray, boolean value) Set all bits tovaluewhich index in indexArraybooleanset(long bitIndex, boolean value) Set bit tovalueat specifiedbitIndexvoidset(long fromIndex, long toIndex) Set all bits to one fromfromIndex(inclusive) totoIndex(exclusive)voidset(long fromIndex, long toIndex, boolean value) Set all bits tovaluefromfromIndex(inclusive) totoIndex(exclusive)voidCopy bits state of source BitSet object to this objectsetAsync(long bitIndex) Set bit to one at specified bitIndexsetAsync(long[] indexArray, boolean value) Set all bits tovaluewhich index in indexArraysetAsync(long bitIndex, boolean value) Set bit tovalueat specifiedbitIndexsetAsync(long fromIndex, long toIndex) Set all bits to one fromfromIndex(inclusive) totoIndex(exclusive)setAsync(long fromIndex, long toIndex, boolean value) Set all bits tovaluefromfromIndex(inclusive) totoIndex(exclusive)Copy bits state of source BitSet object to this objectbytesetByte(long offset, byte value) Returns previous value of byte number and replaces it with definedvalueat specifiedoffsetsetByteAsync(long offset, byte value) Returns previous value of byte number and replaces it with definedvalueat specifiedoffsetintsetInteger(long offset, int value) Returns previous value of integer number and replaces it with definedvalueat specifiedoffsetsetIntegerAsync(long offset, int value) Returns previous value of integer number and replaces it with definedvalueat specifiedoffsetlongsetLong(long offset, long value) Returns previous value of long number and replaces it with definedvalueat specifiedoffsetsetLongAsync(long offset, long value) Returns previous value of long number and replaces it with definedvalueat specifiedoffsetshortsetShort(long offset, short value) Returns previous value of short number and replaces it with definedvalueat specifiedoffsetsetShortAsync(long offset, short value) Returns previous value of short number and replaces it with definedvalueat specifiedoffsetlongsetSigned(int size, long offset, long value) Returns previous value of signed number and replaces it with definedvalueat specifiedoffsetsetSignedAsync(int size, long offset, long value) Returns previous value of signed number and replaces it with definedvalueat specifiedoffsetlongsetUnsigned(int size, long offset, long value) Returns previous value of unsigned number and replaces it with definedvalueat specifiedoffsetsetUnsignedAsync(int size, long offset, long value) Returns previous value of unsigned number and replaces it with definedvalueat specifiedoffsetlongsize()Returns number of set bits.Returns number of set bits.byte[]RFuture<byte[]> protected inttoInt(boolean value) toString()voidExecutes XOR operation over this object and specified bitsets.Executes XOR operation over this object and specified bitsets.Methods inherited from class org.redisson.RedissonObject
addListener, addListener, addListener, addListenerAsync, addListenerAsync, addListenerAsync, addListenerId, addTrackingListener, addTrackingListenerAsync, checkNotBatch, copy, copy, copy, copyAndReplace, copyAndReplace, copyAndReplaceAsync, copyAndReplaceAsync, copyAsync, copyAsync, copyAsync, copyAsync, copyAsync, delete, deleteAsync, deleteAsync, dump, dumpAsync, encode, encode, encode, encode, encodeMapKey, encodeMapKey, encodeMapKeys, encodeMapValue, encodeMapValues, get, getCodec, getIdleTime, getIdleTimeAsync, getListenerIdsByName, getLockByMapKey, getLockByValue, getName, getNameByListenerId, getRawName, getRawName, getServiceManager, getSubscribeService, isExists, isExistsAsync, map, mapName, migrate, migrateAsync, move, moveAsync, prefixName, removeListener, removeListener, removeListenerAsync, removeListenerAsync, removeListenerAsync, removeListenerId, removeListeners, removeTrackingListener, removeTrackingListenerAsync, rename, renameAsync, renameAsync, renameAsync, renamenx, renamenxAsync, renamenxAsync, renamenxAsync, restore, restore, restoreAndReplace, restoreAndReplace, restoreAndReplaceAsync, restoreAndReplaceAsync, restoreAsync, restoreAsync, setName, sizeInMemory, sizeInMemoryAsync, sizeInMemoryAsync, sizeInMemoryAsync, suffixName, toSeconds, toStream, touch, touchAsync, unlink, unlinkAsyncMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.redisson.api.RExpirable
clearExpire, expire, expire, expire, expireAt, expireAt, expireIfGreater, expireIfGreater, expireIfLess, expireIfLess, expireIfNotSet, expireIfNotSet, expireIfSet, expireIfSet, getExpireTime, remainTimeToLiveMethods inherited from interface org.redisson.api.RExpirableAsync
clearExpireAsync, expireAsync, expireAsync, expireAsync, expireAtAsync, expireAtAsync, expireIfGreaterAsync, expireIfGreaterAsync, expireIfLessAsync, expireIfLessAsync, expireIfNotSetAsync, expireIfNotSetAsync, expireIfSetAsync, expireIfSetAsync, getExpireTimeAsync, remainTimeToLiveAsyncMethods inherited from interface org.redisson.api.RObject
addListener, copy, copy, copy, copyAndReplace, copyAndReplace, delete, dump, getCodec, getIdleTime, getName, isExists, migrate, move, removeListener, rename, renamenx, restore, restore, restoreAndReplace, restoreAndReplace, sizeInMemory, touch, unlinkMethods inherited from interface org.redisson.api.RObjectAsync
addListenerAsync, copyAndReplaceAsync, copyAndReplaceAsync, copyAsync, copyAsync, copyAsync, deleteAsync, dumpAsync, getIdleTimeAsync, isExistsAsync, migrateAsync, moveAsync, removeListenerAsync, renameAsync, renamenxAsync, restoreAndReplaceAsync, restoreAndReplaceAsync, restoreAsync, restoreAsync, sizeInMemoryAsync, touchAsync, unlinkAsync
-
Constructor Details
-
RedissonBitSet
-
-
Method Details
-
getSigned
public long getSigned(int size, long offset) Description copied from interface:RBitSetReturns signed number at specifiedoffsetandsize -
setSigned
public long setSigned(int size, long offset, long value) Description copied from interface:RBitSetReturns previous value of signed number and replaces it with definedvalueat specifiedoffset -
incrementAndGetSigned
public long incrementAndGetSigned(int size, long offset, long increment) Description copied from interface:RBitSetIncrements current signed value by definedincrementvalue andsizeat specifiedoffsetand returns result.- Specified by:
incrementAndGetSignedin interfaceRBitSet- Parameters:
size- - size of signed number up to 64 bitsoffset- - offset of signed numberincrement- - increment value- Returns:
- result value
-
getUnsigned
public long getUnsigned(int size, long offset) Description copied from interface:RBitSetReturns unsigned number at specifiedoffsetandsize- Specified by:
getUnsignedin interfaceRBitSet- Parameters:
size- - size of unsigned number up to 64 bitsoffset- - offset of unsigned number- Returns:
- unsigned number
-
setUnsigned
public long setUnsigned(int size, long offset, long value) Description copied from interface:RBitSetReturns previous value of unsigned number and replaces it with definedvalueat specifiedoffset- Specified by:
setUnsignedin interfaceRBitSet- Parameters:
size- - size of unsigned number up to 64 bitsoffset- - offset of unsigned numbervalue- - value of unsigned number- Returns:
- previous value of unsigned number
-
incrementAndGetUnsigned
public long incrementAndGetUnsigned(int size, long offset, long increment) Description copied from interface:RBitSetIncrements current unsigned value by definedincrementvalue andsizeat specifiedoffsetand returns result.- Specified by:
incrementAndGetUnsignedin interfaceRBitSet- Parameters:
size- - size of unsigned number up to 64 bitsoffset- - offset of unsigned numberincrement- - increment value- Returns:
- result value
-
getSignedAsync
Description copied from interface:RBitSetAsyncReturns signed number at specifiedoffsetandsize- Specified by:
getSignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of signed number up to 64 bitsoffset- - offset of signed number- Returns:
- signed number
-
setSignedAsync
Description copied from interface:RBitSetAsyncReturns previous value of signed number and replaces it with definedvalueat specifiedoffset- Specified by:
setSignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of signed number up to 64 bitsoffset- - offset of signed numbervalue- - value of signed number- Returns:
- previous value of signed number
-
incrementAndGetSignedAsync
Description copied from interface:RBitSetAsyncIncrements current signed value by definedincrementvalue andsizeat specifiedoffsetand returns result.- Specified by:
incrementAndGetSignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of signed number up to 64 bitsoffset- - offset of signed numberincrement- - increment value- Returns:
- result value
-
getUnsignedAsync
Description copied from interface:RBitSetAsyncReturns unsigned number at specifiedoffsetandsize- Specified by:
getUnsignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of unsigned number up to 63 bitsoffset- - offset of unsigned number- Returns:
- unsigned number
-
setUnsignedAsync
Description copied from interface:RBitSetAsyncReturns previous value of unsigned number and replaces it with definedvalueat specifiedoffset- Specified by:
setUnsignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of unsigned number up to 63 bitsoffset- - offset of unsigned numbervalue- - value of unsigned number- Returns:
- previous value of unsigned number
-
incrementAndGetUnsignedAsync
Description copied from interface:RBitSetAsyncIncrements current unsigned value by definedincrementvalue andsizeat specifiedoffsetand returns result.- Specified by:
incrementAndGetUnsignedAsyncin interfaceRBitSetAsync- Parameters:
size- - size of unsigned number up to 63 bitsoffset- - offset of unsigned numberincrement- - increment value- Returns:
- result value
-
getByte
public byte getByte(long offset) Description copied from interface:RBitSetReturns byte number at specifiedoffset -
setByte
public byte setByte(long offset, byte value) Description copied from interface:RBitSetReturns previous value of byte number and replaces it with definedvalueat specifiedoffset -
incrementAndGetByte
public byte incrementAndGetByte(long offset, byte increment) Description copied from interface:RBitSetIncrements current byte value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetBytein interfaceRBitSet- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getShort
public short getShort(long offset) Description copied from interface:RBitSetReturns short number at specifiedoffset -
setShort
public short setShort(long offset, short value) Description copied from interface:RBitSetReturns previous value of short number and replaces it with definedvalueat specifiedoffset -
incrementAndGetShort
public short incrementAndGetShort(long offset, short increment) Description copied from interface:RBitSetIncrements current short value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetShortin interfaceRBitSet- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getInteger
public int getInteger(long offset) Description copied from interface:RBitSetReturns integer number at specifiedoffset- Specified by:
getIntegerin interfaceRBitSet- Parameters:
offset- - offset of number- Returns:
- number
-
setInteger
public int setInteger(long offset, int value) Description copied from interface:RBitSetReturns previous value of integer number and replaces it with definedvalueat specifiedoffset- Specified by:
setIntegerin interfaceRBitSet- Parameters:
offset- - offset of numbervalue- - value of number- Returns:
- previous value of number
-
incrementAndGetInteger
public int incrementAndGetInteger(long offset, int increment) Description copied from interface:RBitSetIncrements current integer value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetIntegerin interfaceRBitSet- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getLong
public long getLong(long offset) Description copied from interface:RBitSetReturns long number at specifiedoffset -
setLong
public long setLong(long offset, long value) Description copied from interface:RBitSetReturns previous value of long number and replaces it with definedvalueat specifiedoffset -
incrementAndGetLong
public long incrementAndGetLong(long offset, long increment) Description copied from interface:RBitSetIncrements current long value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetLongin interfaceRBitSet- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getByteAsync
Description copied from interface:RBitSetAsyncReturns byte number at specifiedoffset- Specified by:
getByteAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of number- Returns:
- number
-
setByteAsync
Description copied from interface:RBitSetAsyncReturns previous value of byte number and replaces it with definedvalueat specifiedoffset- Specified by:
setByteAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numbervalue- - value of number- Returns:
- previous value of number
-
incrementAndGetByteAsync
Description copied from interface:RBitSetAsyncIncrements current byte value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetByteAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getShortAsync
Description copied from interface:RBitSetAsyncReturns short number at specifiedoffset- Specified by:
getShortAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of number- Returns:
- number
-
setShortAsync
Description copied from interface:RBitSetAsyncReturns previous value of short number and replaces it with definedvalueat specifiedoffset- Specified by:
setShortAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numbervalue- - value of number- Returns:
- previous value of number
-
incrementAndGetShortAsync
Description copied from interface:RBitSetAsyncIncrements current short value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetShortAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getIntegerAsync
Description copied from interface:RBitSetAsyncReturns integer number at specifiedoffset- Specified by:
getIntegerAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of number- Returns:
- number
-
setIntegerAsync
Description copied from interface:RBitSetAsyncReturns previous value of integer number and replaces it with definedvalueat specifiedoffset- Specified by:
setIntegerAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numbervalue- - value of number- Returns:
- previous value of number
-
incrementAndGetIntegerAsync
Description copied from interface:RBitSetAsyncIncrements current integer value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetIntegerAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
getLongAsync
Description copied from interface:RBitSetAsyncReturns long number at specifiedoffset- Specified by:
getLongAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of number- Returns:
- number
-
setLongAsync
Description copied from interface:RBitSetAsyncReturns previous value of long number and replaces it with definedvalueat specifiedoffset- Specified by:
setLongAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numbervalue- - value of number- Returns:
- previous value of number
-
incrementAndGetLongAsync
Description copied from interface:RBitSetAsyncIncrements current long value on definedincrementvalue at specifiedoffsetand returns result.- Specified by:
incrementAndGetLongAsyncin interfaceRBitSetAsync- Parameters:
offset- - offset of numberincrement- - increment value- Returns:
- result value
-
length
public long length()Description copied from interface:RBitSetReturns "logical size" = index of highest set bit plus one. Returns zero if there are no any set bit. -
set
Description copied from interface:RBitSetCopy bits state of source BitSet object to this object -
set
public void set(long[] indexArray, boolean value) Description copied from interface:RBitSetSet all bits tovaluewhich index in indexArray -
get
public boolean get(long bitIndex) Description copied from interface:RBitSetReturnstrueif bit set to one andfalseoverwise. -
getAsync
Description copied from interface:RBitSetAsyncReturnstrueif bit set to one andfalseoverwise.- Specified by:
getAsyncin interfaceRBitSetAsync- Parameters:
bitIndex- - index of bit- Returns:
trueif bit set to one andfalseoverwise.
-
set
public boolean set(long bitIndex) Description copied from interface:RBitSetSet bit to one at specified bitIndex -
set
public void set(long fromIndex, long toIndex, boolean value) Description copied from interface:RBitSetSet all bits tovaluefromfromIndex(inclusive) totoIndex(exclusive) -
set
public void set(long fromIndex, long toIndex) Description copied from interface:RBitSetSet all bits to one fromfromIndex(inclusive) totoIndex(exclusive) -
set
public boolean set(long bitIndex, boolean value) Description copied from interface:RBitSetSet bit tovalueat specifiedbitIndex -
setAsync
Description copied from interface:RBitSetAsyncSet bit tovalueat specifiedbitIndex- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
bitIndex- - index of bitvalue- true = 1, false = 0- Returns:
true- if previous value was true,false- if previous value was false
-
toInt
protected int toInt(boolean value) -
setAsync
Description copied from interface:RBitSetAsyncSet all bits tovaluewhich index in indexArray- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
indexArray- The index array of bits that needs to be set tovaluevalue- true = 1, false = 0
-
toByteArray
public byte[] toByteArray()- Specified by:
toByteArrayin interfaceRBitSet
-
toByteArrayAsync
- Specified by:
toByteArrayAsyncin interfaceRBitSetAsync
-
cardinality
public long cardinality()Description copied from interface:RBitSetReturns the number of bits set to one.- Specified by:
cardinalityin interfaceRBitSet- Returns:
- number of bits
-
size
public long size()Description copied from interface:RBitSetReturns number of set bits. -
clear
public void clear(long fromIndex, long toIndex) Description copied from interface:RBitSetSet all bits to zero fromfromIndex(inclusive) totoIndex(exclusive) -
clear
public boolean clear(long bitIndex) Description copied from interface:RBitSetSet bit to zero at specifiedbitIndex -
clear
public void clear()Description copied from interface:RBitSetSet all bits to zero -
or
Description copied from interface:RBitSetExecutes OR operation over this object and specified bitsets. Stores result into this object. -
and
Description copied from interface:RBitSetExecutes AND operation over this object and specified bitsets. Stores result into this object. -
xor
Description copied from interface:RBitSetExecutes XOR operation over this object and specified bitsets. Stores result into this object. -
not
public void not()Description copied from interface:RBitSetExecutes NOT operation over all bits -
asBitSet
-
toString
-
lengthAsync
Description copied from interface:RBitSetAsyncReturns "logical size" = index of highest set bit plus one. Returns zero if there are no any set bit.- Specified by:
lengthAsyncin interfaceRBitSetAsync- Returns:
- "logical size" = index of highest set bit plus one
-
setAsync
Description copied from interface:RBitSetAsyncSet all bits tovaluefromfromIndex(inclusive) totoIndex(exclusive)- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
fromIndex- inclusivetoIndex- exclusivevalue- true = 1, false = 0- Returns:
- void
-
clearAsync
Description copied from interface:RBitSetAsyncSet all bits to zero fromfromIndex(inclusive) totoIndex(exclusive)- Specified by:
clearAsyncin interfaceRBitSetAsync- Parameters:
fromIndex- inclusivetoIndex- exclusive- Returns:
- void
-
setAsync
Description copied from interface:RBitSetAsyncCopy bits state of source BitSet object to this object- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
bs- - BitSet source- Returns:
- void
-
notAsync
Description copied from interface:RBitSetAsyncExecutes NOT operation over all bits- Specified by:
notAsyncin interfaceRBitSetAsync- Returns:
- void
-
setAsync
Description copied from interface:RBitSetAsyncSet all bits to one fromfromIndex(inclusive) totoIndex(exclusive)- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
fromIndex- inclusivetoIndex- exclusive- Returns:
- void
-
sizeAsync
Description copied from interface:RBitSetAsyncReturns number of set bits.- Specified by:
sizeAsyncin interfaceRBitSetAsync- Returns:
- number of set bits.
-
setAsync
Description copied from interface:RBitSetAsyncSet bit to one at specified bitIndex- Specified by:
setAsyncin interfaceRBitSetAsync- Parameters:
bitIndex- - index of bit- Returns:
true- if previous value was true,false- if previous value was false
-
cardinalityAsync
Description copied from interface:RBitSetAsyncReturns the number of bits set to one.- Specified by:
cardinalityAsyncin interfaceRBitSetAsync- Returns:
- number of bits
-
clearAsync
Description copied from interface:RBitSetAsyncSet bit to zero at specifiedbitIndex- Specified by:
clearAsyncin interfaceRBitSetAsync- Parameters:
bitIndex- - index of bit- Returns:
true- if previous value was true,false- if previous value was false
-
clearAsync
Description copied from interface:RBitSetAsyncSet all bits to zero- Specified by:
clearAsyncin interfaceRBitSetAsync- Returns:
- void
-
orAsync
Description copied from interface:RBitSetAsyncExecutes OR operation over this object and specified bitsets. Stores result into this object.- Specified by:
orAsyncin interfaceRBitSetAsync- Parameters:
bitSetNames- - name of stored bitsets- Returns:
- void
-
andAsync
Description copied from interface:RBitSetAsyncExecutes AND operation over this object and specified bitsets. Stores result into this object.- Specified by:
andAsyncin interfaceRBitSetAsync- Parameters:
bitSetNames- - name of stored bitsets- Returns:
- void
-
xorAsync
Description copied from interface:RBitSetAsyncExecutes XOR operation over this object and specified bitsets. Stores result into this object.- Specified by:
xorAsyncin interfaceRBitSetAsync- Parameters:
bitSetNames- - name of stored bitsets- Returns:
- void
-
expire
Description copied from interface:RExpirableUseRExpirable.expire(Duration)instead- Specified by:
expirein interfaceRExpirable- Parameters:
timeToLive- - timeout before object will be deletedtimeUnit- - timeout time unit- Returns:
trueif the timeout was set andfalseif not
-
expireAsync
Description copied from interface:RExpirableAsyncUseRExpirableAsync.expireAsync(Duration)instead- Specified by:
expireAsyncin interfaceRExpirableAsync- Parameters:
timeToLive- - timeout before object will be deletedtimeUnit- - timeout time unit- Returns:
trueif the timeout was set andfalseif not
-
expireAt
public boolean expireAt(long timestamp) Description copied from interface:RExpirableUseRExpirable.expire(Instant)instead- Specified by:
expireAtin interfaceRExpirable- Parameters:
timestamp- - expire date in milliseconds (Unix timestamp)- Returns:
trueif the timeout was set andfalseif not
-
expireAtAsync
Description copied from interface:RExpirableAsyncUseRExpirableAsync.expireAsync(Instant)instead- Specified by:
expireAtAsyncin interfaceRExpirableAsync- Parameters:
timestamp- - expire date in milliseconds (Unix timestamp)- Returns:
trueif the timeout was set andfalseif not
-
expire
Description copied from interface:RExpirableSets an expiration date for this object. When expire date comes the key will automatically be deleted.- Specified by:
expirein interfaceRExpirable- Parameters:
instant- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfSet
Description copied from interface:RExpirableSets an expiration date for this object only if it has been already set. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfSetin interfaceRExpirable- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfSetAsync
Description copied from interface:RExpirableAsyncSets an expiration date for this object only if it has been already set. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfSetAsyncin interfaceRExpirableAsync- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfNotSet
Description copied from interface:RExpirableSets an expiration date for this object only if it hasn't been set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfNotSetin interfaceRExpirable- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfNotSetAsync
Description copied from interface:RExpirableAsyncSets an expiration date for this object only if it hasn't been set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfNotSetAsyncin interfaceRExpirableAsync- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfGreater
Description copied from interface:RExpirableSets an expiration date for this object only if it's greater than expiration date set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfGreaterin interfaceRExpirable- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfGreaterAsync
Description copied from interface:RExpirableAsyncSets an expiration date for this object only if it's greater than expiration date set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfGreaterAsyncin interfaceRExpirableAsync- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfLess
Description copied from interface:RExpirableSets an expiration date for this object only if it's less than expiration date set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfLessin interfaceRExpirable- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfLessAsync
Description copied from interface:RExpirableAsyncSets an expiration date for this object only if it's less than expiration date set before. When expire date comes the object will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfLessAsyncin interfaceRExpirableAsync- Parameters:
time- expire date- Returns:
trueif the timeout was set andfalseif not
-
expireAsync
Description copied from interface:RExpirableAsyncSet an expire date for object. When expire date comes the key will automatically be deleted.- Specified by:
expireAsyncin interfaceRExpirableAsync- Parameters:
instant- - expire date- Returns:
trueif the timeout was set andfalseif not
-
expire
Description copied from interface:RExpirableSets a timeout for this object. After the timeout has expired, the key will automatically be deleted.- Specified by:
expirein interfaceRExpirable- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireAsync
Description copied from interface:RExpirableAsyncSet a timeout for object. After the timeout has expired, the key will automatically be deleted.- Specified by:
expireAsyncin interfaceRExpirableAsync- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireAt
Description copied from interface:RExpirableUseRExpirable.expire(Instant)instead- Specified by:
expireAtin interfaceRExpirable- Parameters:
timestamp- - expire date- Returns:
trueif the timeout was set andfalseif not
-
expireAtAsync
Description copied from interface:RExpirableAsyncUseRExpirableAsync.expireAsync(Instant)instead- Specified by:
expireAtAsyncin interfaceRExpirableAsync- Parameters:
timestamp- - expire date- Returns:
trueif the timeout was set andfalseif not
-
expireIfSet
Description copied from interface:RExpirableSets a timeout for this object only if it has been already set. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfSetin interfaceRExpirable- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfSetAsync
Description copied from interface:RExpirableAsyncSets a timeout for this object only if it has been already set. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfSetAsyncin interfaceRExpirableAsync- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfNotSet
Description copied from interface:RExpirableSets a timeout for this object only if it hasn't been set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfNotSetin interfaceRExpirable- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfNotSetAsync
Description copied from interface:RExpirableAsyncSets a timeout for this object only if it hasn't been set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfNotSetAsyncin interfaceRExpirableAsync- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfGreater
Description copied from interface:RExpirableSets a timeout for this object only if it's greater than timeout set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfGreaterin interfaceRExpirable- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfGreaterAsync
Description copied from interface:RExpirableAsyncSets a timeout for this object only if it's greater than timeout set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfGreaterAsyncin interfaceRExpirableAsync- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfLess
Description copied from interface:RExpirableSets a timeout for this object only if it's less than timeout set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfLessin interfaceRExpirable- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
expireIfLessAsync
Description copied from interface:RExpirableAsyncSets a timeout for this object only if it's less than timeout set before. After the timeout has expired, the key will automatically be deleted.Requires Redis 7.0.0 and higher.
- Specified by:
expireIfLessAsyncin interfaceRExpirableAsync- Parameters:
duration- timeout before object will be deleted- Returns:
trueif the timeout was set andfalseif not
-
clearExpire
public boolean clearExpire()Description copied from interface:RExpirableClear an expire timeout or expire date for object.- Specified by:
clearExpirein interfaceRExpirable- Returns:
trueif timeout was removedfalseif object does not exist or does not have an associated timeout
-
clearExpireAsync
Description copied from interface:RExpirableAsyncClear an expire timeout or expire date for object in async mode. Object will not be deleted.- Specified by:
clearExpireAsyncin interfaceRExpirableAsync- Returns:
trueif the timeout was cleared andfalseif not
-
remainTimeToLive
public long remainTimeToLive()Description copied from interface:RExpirableReturns remaining time of the object in milliseconds.- Specified by:
remainTimeToLivein interfaceRExpirable- Returns:
- time in milliseconds -2 if the key does not exist. -1 if the key exists but has no associated expire.
-
remainTimeToLiveAsync
Description copied from interface:RExpirableAsyncReturns remaining time of the object in milliseconds.- Specified by:
remainTimeToLiveAsyncin interfaceRExpirableAsync- Returns:
- time in milliseconds -2 if the key does not exist. -1 if the key exists but has no associated expire.
-
getExpireTime
public long getExpireTime()Description copied from interface:RExpirableReturns expiration time of the object as the absolute Unix expiration timestamp in milliseconds.Requires Redis 7.0.0 and higher.
- Specified by:
getExpireTimein interfaceRExpirable- Returns:
- Unix time in milliseconds -2 if the key does not exist. -1 if the key exists but has no associated expiration time.
-
getExpireTimeAsync
Description copied from interface:RExpirableAsyncReturns expiration time of the object as the absolute Unix expiration timestamp in milliseconds.Requires Redis 7.0.0 and higher.
- Specified by:
getExpireTimeAsyncin interfaceRExpirableAsync- Returns:
- Unix time in milliseconds -2 if the key does not exist. -1 if the key exists but has no associated expiration time.
-
expireAsync
-
expireAtAsync
-
clearExpireAsync
-