• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 package com.fasterxml.jackson.core.async;
2 
3 import java.io.IOException;
4 
5 /**
6  * {@link NonBlockingInputFeeder} implementation used when feeding data
7  * as byte arrays.
8  *
9  * @since 2.9
10  */
11 public interface ByteArrayFeeder extends NonBlockingInputFeeder
12 {
13      /**
14       * Method that can be called to feed more data, if (and only if)
15       * {@link #needMoreInput} returns true.
16       *
17       * @param data Byte array that contains data to feed: caller must ensure data remains
18       *    stable until it is fully processed (which is true when {@link #needMoreInput}
19       *    returns true)
20       * @param offset Offset within array where input data to process starts
21       * @param end Offset after last byte contained in the input array
22       *
23       * @throws IOException if the state is such that this method should not be called
24       *   (has not yet consumed existing input data, or has been marked as closed)
25       */
feedInput(byte[] data, int offset, int end)26      public void feedInput(byte[] data, int offset, int end) throws IOException;
27 }
28