Pracuje z tą biblioteką:
https://github.com/omaraflak/Bluetooth-Library#receive-messages

U dołu strony jest taka oto klasa do odbioru danych zaproponowana:

public class DelimiterReader extends SocketReader {
    private PushbackInputStream reader;
    private byte delimiter;

    public DelimiterReader(InputStream inputStream) {
        super(inputStream);
        reader = new PushbackInputStream(inputStream);
        delimiter = 0;
    }

    @Override
    public byte[] read() throws IOException {
        List<Byte> byteList = new ArrayList<>();
        byte[] tmp = new byte[1];

        while(true) {
            int n = reader.read();
            reader.unread(n);

            int count = reader.read(tmp);
            if(count > 0) {
                if(tmp[0] == delimiter){
                    byte[] returnBytes = new byte[byteList.size()];
                    for(int i=0 ; i<byteList.size() ; i++){
                        returnBytes[i] = byteList.get(i);
                    }
                    return returnBytes;
                } else {
                    byteList.add(tmp[0]);
                }
            }
        }
    }
}

Dane są odbierane gdy jest ich dużo tzn. np. 200B naraz, natomiest przy np. 10B nie odbiera się nic.
Próbuje pojąć co tu sie dzieje, ale nie mogę sie przez to przebić.
Proszę o pomoc w wytłumaczeniu. Jakie zdanie ma PushbackInputStream?