Function
| Static Public Summary | ||
| public |
add32(a: *, b: *) Adds to 32-bit signed integers. |
|
| public |
big32(a: *, o: *): * Construct a 32-bit signed integer from 4 bytes. |
|
| public |
get32(w: *): * Creates a 32-bit signed integer from anything. |
|
| public |
lil32(a: *, o: *): * |
|
| public |
rotl32(word: *, shift: *): * Left rotate for 32-bit unsigned integers |
|
| public |
rotr32(word: *, shift: *): * Right rotate for 32-bit unsigned integers |
|
| public |
sqrt32(n: *): * |
|
| public |
usqrt32(n: *): * |
|
Static Public
public add32(a: *, b: *) source
import {add32} from '@arithmetic-type/uint32/src/add32.js'Adds to 32-bit signed integers.
Params:
| Name | Type | Attribute | Description |
| a | * | ||
| b | * |
public big32(a: *, o: *): * source
import {big32} from '@arithmetic-type/uint32/src/big32.js'Construct a 32-bit signed integer from 4 bytes.
Params:
| Name | Type | Attribute | Description |
| a | * | ||
| o | * |
Return:
| * |
public get32(w: *): * source
import {get32} from '@arithmetic-type/uint32/src/get32.js'Creates a 32-bit signed integer from anything.
Params:
| Name | Type | Attribute | Description |
| w | * |
Return:
| * |
Example:
get32(0xFFFFFFFF); // -1
public lil32(a: *, o: *): * source
import {lil32} from '@arithmetic-type/uint32/src/lil32.js'Params:
| Name | Type | Attribute | Description |
| a | * | ||
| o | * |
Return:
| * |
public rotl32(word: *, shift: *): * source
import {rotl32} from '@arithmetic-type/uint32/src/rotl32.js'Left rotate for 32-bit unsigned integers
- used in md5 and sha1
Params:
| Name | Type | Attribute | Description |
| word | * | ||
| shift | * |
Return:
| * |
public rotr32(word: *, shift: *): * source
import {rotr32} from '@arithmetic-type/uint32/src/rotr32.js'Right rotate for 32-bit unsigned integers
Params:
| Name | Type | Attribute | Description |
| word | * | ||
| shift | * |
Return:
| * |
public sqrt32(n: *): * source
import {sqrt32} from '@arithmetic-type/uint32/src/sqrt32.js'Params:
| Name | Type | Attribute | Description |
| n | * |
Return:
| * |
public usqrt32(n: *): * source
import {usqrt32} from '@arithmetic-type/uint32/src/usqrt32.js'Params:
| Name | Type | Attribute | Description |
| n | * |
Return:
| * |
