Passed
Pull Request — master (#6)
by
unknown
02:58
created

endianness.d.ts   A

Complexity

Total Complexity 2
Complexity/F 1

Size

Lines of Code 19
Function Count 2

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 6
mnd 0
bc 0
fnc 2
dl 0
loc 19
bpm 0
cpm 1
noi 0
c 0
b 0
f 0
rs 10
1
// Type definitions for endianness 8.0
2
// Project: https://github.com/rochars/endianness
3
// Definitions by: Rafael da Silva Rocha <https://github.com/rochars>
4
// Definitions: https://github.com/rochars/endianness
5
6
/**
7
 * Swap the byte ordering in a buffer. The buffer is modified in place.
8
 * @param {!Array|!Uint8Array} bytes The bytes.
9
 * @param {number} offset The byte offset.
10
 * @param {number=} start The start index. Assumes 0.
11
 * @param {number=} end The end index. Assumes the buffer length.
12
 * @throws {Error} If the buffer length is not valid.
13
 */
14
export default function endianness(
15
	bytes: number[]|Uint8Array,
16
	offset: number,
17
	start?: number,
18
	end?: number): void;
19