-
-
- serialVersionUID:
- -6663013367427929992L
-
Serialization Methods
-
readObject
Reconstitute the SparseBitSet
instance from a stream
(i.e., deserialize it).
- Parameters:
s
- the ObjectInputStream to use
- Throws:
IOException
- if there is an io error
ClassNotFoundException
- if the stream contains an unidentified
class
- Since:
- 1.6
-
writeObject
Save the state of the SparseBitSet
instance to a stream
(i.e., serialize it).
- Serial Data:
- The default data is emitted, followed by the current
compactionCount for the bit set, and then the
length of the set (the position of the last bit),
followed by the cache.count value (an
int
,
the number of int->long
pairs needed to describe
the set), followed by the index (int
) and word
(long
) for each int->long
pair.
The mappings need not be emitted in any particular order. This
is followed by the hashCode for the set that can be used
as an integrity check when the bit set is read back.
- Parameters:
s
- the ObjectOutputStream to which to write the serialized object
- Throws:
IOException
- if an io error occurs
InternalError
- if the SparseBitSet representation is
inconsistent
- Since:
- 1.6