@Nullable
	public Integer getIntValue(@IntFormat final int formatType,
							   @IntRange(from = 0) final int offset) {
		if ((offset + getTypeLen(formatType)) > size()) return null;

		return switch (formatType) {
			case FORMAT_UINT8 -> unsignedByteToInt(mValue[offset]);
			case FORMAT_UINT16_LE -> unsignedBytesToInt(mValue[offset], mValue[offset + 1]);
			case FORMAT_UINT16_BE -> unsignedBytesToInt(mValue[offset + 1], mValue[offset]);
			case FORMAT_UINT24_LE -> unsignedBytesToInt(
					mValue[offset],
					mValue[offset + 1],
					mValue[offset + 2],
					(byte) 0
			);
			case FORMAT_UINT24_BE -> unsignedBytesToInt(
					mValue[offset + 2],
					mValue[offset + 1],
					mValue[offset],
					(byte) 0
			);
			case FORMAT_UINT32_LE -> unsignedBytesToInt(
					mValue[offset],
					mValue[offset + 1],
					mValue[offset + 2],
					mValue[offset + 3]
			);
			case FORMAT_UINT32_BE -> unsignedBytesToInt(
					mValue[offset + 3],
					mValue[offset + 2],
					mValue[offset + 1],
					mValue[offset]
			);
			case FORMAT_SINT8 -> unsignedToSigned(unsignedByteToInt(mValue[offset]), 8);
			case FORMAT_SINT16_LE -> unsignedToSigned(unsignedBytesToInt(mValue[offset],
					mValue[offset + 1]), 16);
			case FORMAT_SINT16_BE -> unsignedToSigned(unsignedBytesToInt(mValue[offset + 1],
					mValue[offset]), 16);
			case FORMAT_SINT24_LE -> unsignedToSigned(unsignedBytesToInt(
					mValue[offset],
					mValue[offset + 1],
					mValue[offset + 2],
					(byte) 0
			), 24);
			case FORMAT_SINT24_BE -> unsignedToSigned(unsignedBytesToInt(
					(byte) 0,
					mValue[offset + 2],
					mValue[offset + 1],
					mValue[offset]
			), 24);
			case FORMAT_SINT32_LE -> unsignedToSigned(unsignedBytesToInt(
					mValue[offset],
					mValue[offset + 1],
					mValue[offset + 2],
					mValue[offset + 3]
			), 32);
			case FORMAT_SINT32_BE -> unsignedToSigned(unsignedBytesToInt(
					mValue[offset + 3],
					mValue[offset + 2],
					mValue[offset + 1],
					mValue[offset]
			), 32);
			default -> null;
		};

	}
Returns an integer value from the byte array.
<p>
<p>The formatType parameter determines how the value
is to be interpreted. For example, setting formatType to
{@link #FORMAT_UINT16_LE} specifies that the first two bytes of the
value at the given offset are interpreted to generate the
return value.

@param formatType The format type used to interpret the value.
@param offset     Offset at which the integer value can be found.
@return Cached value or null of offset exceeds value size.
ble/src/main/java/no/nordicsemi/android/ble/data/Data.java