Skip to content

Commit

Permalink
fix ts definition, remove deserialize from readonly interface
Browse files Browse the repository at this point in the history
  • Loading branch information
SalvatorePreviti committed Feb 5, 2023
1 parent 8fdaf98 commit ba7525b
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -760,22 +760,6 @@ export interface ReadonlyRoaringBitmap32 extends ReadonlySet<number> {
format: SerializationFormatType,
): Promise<Buffer>;

/**
* Deserializes the bitmap from an Uint8Array or a Buffer.
*
* Setting the portable flag to false enable a custom format that can save space compared to the portable format (e.g., for very sparse bitmaps).
* The portable version is meant to be compatible with Java and Go versions.
*
* @param {Uint8Array | Int8Array | Uint8ClampedArray | ArrayBuffer} serialized An Uint8Array or a node Buffer that contains the serialized data.
* @param {DeserializationFormatType} format The format of the serialized data. true means "portable". false means "croaring".
* @returns {this} This ReadonlyRoaringBitmap32 instance.
* @memberof ReadonlyRoaringBitmap32
*/
deserialize(
serialized: Uint8Array | Int8Array | Uint8ClampedArray | ArrayBuffer,
format: DeserializationFormatType,
): this;

/**
* Returns a new ReadonlyRoaringBitmap32 that is a copy of this bitmap, same as new ReadonlyRoaringBitmap32(copy)
*
Expand Down Expand Up @@ -1160,6 +1144,22 @@ export interface RoaringBitmap32 extends ReadonlyRoaringBitmap32, Set<number> {
* The readonlyView bitmap is readonly, so it is not possible to modify it.
*/
asReadonlyView(): ReadonlyRoaringBitmap32;

/**
* Deserializes the bitmap from an Uint8Array or a Buffer.
*
* Setting the portable flag to false enable a custom format that can save space compared to the portable format (e.g., for very sparse bitmaps).
* The portable version is meant to be compatible with Java and Go versions.
*
* @param {Uint8Array | Int8Array | Uint8ClampedArray | ArrayBuffer} serialized An Uint8Array or a node Buffer that contains the serialized data.
* @param {DeserializationFormatType} format The format of the serialized data. true means "portable". false means "croaring".
* @returns {this} This ReadonlyRoaringBitmap32 instance.
* @memberof ReadonlyRoaringBitmap32
*/
deserialize(
serialized: Uint8Array | Int8Array | Uint8ClampedArray | ArrayBuffer,
format: DeserializationFormatType,
): this;
}

/**
Expand Down

0 comments on commit ba7525b

Please sign in to comment.