private SparseArray<byte[]> removeLowerTransportControlMessageHeader(@NonNull final ControlMessage message) {
        final SparseArray<byte[]> messages = message.getLowerTransportControlPdu();
        if (messages.size() > 1) {
            for (int i = 0; i < messages.size(); i++) {
                final byte[] data = messages.get(i);
                final int length = data.length - SEGMENTED_MESSAGE_HEADER_LENGTH; //header size of unsegmented messages is 4;
                messages.put(i, removeHeader(data, 4, length));
            }
        } else {
            final int opCode = message.getOpCode();
            final byte[] data;
            final int length;
            if (opCode == TransportLayerOpCodes.SAR_ACK_OPCODE) {
                data = messages.get(0);
                length = data.length - UNSEGMENTED_ACK_MESSAGE_HEADER_LENGTH; //header size of unsegmented acknowledgement messages is 3;
                messages.put(0, removeHeader(data, UNSEGMENTED_ACK_MESSAGE_HEADER_LENGTH, length));
            } else {
                data = messages.get(0);
                length = data.length - UNSEGMENTED_MESSAGE_HEADER_LENGTH; //header size of unsegmented messages is 1;
                messages.put(0, removeHeader(data, UNSEGMENTED_MESSAGE_HEADER_LENGTH, length));
            }
        }
        return messages;
    }
Removes the transport header of the control message.

@param message control message.
@return map containing the messages.
mesh/src/main/java/no/nordicsemi/android/mesh/transport/LowerTransportLayer.java