private SparseArray<byte[]> removeLowerTransportAccessMessageHeader(@NonNull final AccessMessage message) {
        final SparseArray<byte[]> messages = message.getLowerTransportAccessPdu();
        if (message.isSegmented()) {
            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 byte[] data = messages.get(0);
            final int length = data.length - UNSEGMENTED_MESSAGE_HEADER_LENGTH; //header size of unsegmented messages is 1;
            messages.put(0, removeHeader(data, 1, length));
        }
        return messages;
    }
Removes the transport header of the access message.

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